From: Marty Connor Date: Thu, 14 Sep 2006 17:38:17 +0000 (+0000) Subject: update DBG_DISCARD macro to allow the compiler to see the argument for compile-time... X-Git-Tag: v0.9.3~1046 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=e2aca77132d42aefa2d7a2346a4a3fd910c8e2a9;p=thirdparty%2Fipxe.git update DBG_DISCARD macro to allow the compiler to see the argument for compile-time checking, while still having it optimized away during compilation --- diff --git a/src/include/compiler.h b/src/include/compiler.h index f2e63f1dd..3aee4a603 100644 --- a/src/include/compiler.h +++ b/src/include/compiler.h @@ -124,7 +124,9 @@ __asm__ ( ".equ\tDEBUG_LEVEL, " DEBUG_SYMBOL_STR ); #endif #define DBG_PRINT(...) printf ( __VA_ARGS__ ) -#define DBG_DISCARD(...) do {} while ( 0 ) +#define DBG_DISCARD(...) do { if ( 0 ) printf ( __VA_ARGS__ ); } while ( 0 ) +/*#define DBG_DISCARD(...) do {} while ( 0 )*/ + #define DBG DBG_DISCARD #define DBG2 DBG_DISCARD