libnjb: /usr/obj/ports/libnjb-2.2.7/libnjb-2.2.7/src/defs.h Source File

libnjb 2.2.7

defs.h
1 #ifndef __NJB__DEFS__H
2 #define __NJB__DEFS__H
3
4 /* Takes out GCC weirdness for other compilers */
5 #ifndef __GNUC__
6 # define __attribute__(x) /*NOTHING*/
7 #endif
8
9 /* Macros for printing debug traces from subroutines */
10 #define __dsub static char *subroutinename __attribute__((unused))
11 #define __sub subroutinename
12 #define __enter if(njb_debug(DD_SUBTRACE))fprintf(stderr,"%*s==> %s\n",3*__sub_depth++,"",__sub)
13 #define __leave if(njb_debug(DD_SUBTRACE))fprintf(stderr,"%*s<== %s\n",3*(--__sub_depth),"",__sub)
14
15 #endif