2 warn.cc -- implement warning and error messages. Needs cleanup.
4 source file of the GNU LilyPond music typesetter
6 (c) 1997--1998 Han-Wen Nienhuys <hanwen@cs.uu.nl>
12 #include "my-lily-lexer.hh"
14 #include "time-description.hh"
15 #include "source-file.hh"
20 ostream
&warnout (cerr
);
21 ostream
*mlog (&cerr
);
26 error_t (String
const & s
, Moment
const & r
)
28 String t_mom
= r
.truncated ().str () + (r
- r
.truncated ()).str ();
29 String e
=s
+ " (t = " + t_mom
+ ")";
34 error_t (String
const & s
, Time_description
const &t_tdes
)
36 String e
=s
+ " (at t=" + to_str (t_tdes
.bars_i_
) + ": " + (t_tdes
.whole_in_measure_
).str () + ")\n";