]> git.donarmstrong.com Git - lilypond.git/blob - hdr/debug.hh
release: 0.0.26
[lilypond.git] / hdr / debug.hh
1 #ifndef DEBUG_HH
2 #define DEBUG_HH
3
4 #include <assert.h>
5 #include <iostream.h>
6 #include "dstream.hh"
7 #include "real.hh"
8 #include "proto.hh"
9
10 void error(String s);           // errors
11 void error_t(const String& s, Time_description const &  t_tdes);
12 void error_t(String const &s, const Moment &when);
13 // warnings
14 //void warning(String s);
15 #define WARN warnout << "warning: "<<__FUNCTION__ << "(): "
16 extern ostream &warnout ;
17
18 // progress
19 extern ostream *mlog;
20
21 // debugging
22 extern Dstream monitor; // monitor
23
24 #ifdef NPRINT
25 #define mtor if (0) monitor     // clever hack 
26 #else
27 #define mtor if (check_debug) monitor.identify_as(__PRETTY_FUNCTION__)
28 #endif
29
30 extern bool check_debug;
31
32 #endif