home *** CD-ROM | disk | FTP | other *** search
/ The Best of Mecomp Multimedia 2 / MECOMP-CD-II.iso / amiga / datatypes / mididt / source / debug.h next >
Encoding:
C/C++ Source or Header  |  1997-10-03  |  577 b   |  36 lines

  1. #ifndef DEBUG_H
  2. #define DEBUG_H
  3.  
  4. /*
  5. ** debug.h
  6. **
  7. ** $VER: debug.h 1.0 (11.09.97)
  8. **
  9. ** Created by Stefan Ruppert, modifyed by Martin Gierich for midi.datatype.
  10. */
  11.  
  12.  
  13. #define bug      kprintf
  14.  
  15. #ifdef DEBUG
  16.  
  17. extern void kprintf(char *fmt,...);
  18.  
  19. #define D(x)    x
  20. #define DB(x)   { bug(__FILE__ "(%4ld):" __FUNC__ "() :",__LINE__); \
  21.                   bug x; \
  22.                 }
  23. #define ENTERING  bug("entering " __FUNC__ "()\n")
  24. #define LEAVING   bug("leaving " __FUNC__ "()\n")
  25.  
  26. #else
  27.  
  28. #define D(x)
  29. #define DB(x)
  30. #define ENTERING
  31. #define LEAVING
  32.  
  33. #endif
  34.  
  35. #endif   /* DEBUG_H */
  36.