]> git.donarmstrong.com Git - lilypond.git/blob - src/warn.cc
release: 0.0.13
[lilypond.git] / src / warn.cc
1 #include "debug.hh"
2 #include "lexer.hh"
3
4 ostream &warnout (cerr);
5 ostream *mlog(&cerr);
6
7
8
9 void
10 warning(String s)
11 {
12     WARN << s;
13 }
14
15
16 void
17 error(String s)
18 {
19     if (busy_parsing())
20         yyerror(s);
21     else
22         cerr <<  "\nerror: " << s << "\n";
23         
24     exit(1);
25 }
26
27 void
28 error_t(String s, Real r)
29 {
30     String e=s+ "(t = " + r + ")";
31     error(e);
32     exit(1);
33 }
34