Details | Last modification | View Log | RSS feed
| Rev | Author | Line No. | Line |
|---|---|---|---|
| 244 | chris | 1 | #ifndef __DEBUG_INCLUDED__ |
| 2 | #define __DEBUG_INCLUDED__ |
||
| 3 | |||
| 4 | #include "Common.h" |
||
| 5 | #include <cassert> |
||
| 6 | |||
| 7 | extern bool gInAssert; |
||
| 8 | |||
| 9 | #ifdef SEXY_TRACING_ENABLED |
||
| 10 | void SexyTrace(const char *theStr); |
||
| 11 | #define SEXY_TRACE(theStr) SexyTrace(theStr) |
||
| 12 | #else |
||
| 13 | #define SEXY_TRACE(theStr) |
||
| 14 | #endif |
||
| 15 | |||
| 16 | extern void SexyTraceFmt(const SexyChar* fmt ...); |
||
| 17 | extern void OutputDebug(const SexyChar* fmt ...); |
||
| 18 | |||
| 19 | #ifdef NDEBUG |
||
| 20 | |||
| 21 | #define DBG_ASSERTE(exp) ((void)0) |
||
| 22 | #define DBG_ASSERT(exp) ((void)0) |
||
| 23 | |||
| 24 | #else |
||
| 25 | |||
| 26 | #define DBG_ASSERTE(exp) { gInAssert = true; assert(exp); gInAssert = false; } |
||
| 27 | #define DBG_ASSERT(exp) { gInAssert = true; assert(exp); gInAssert = false; } |
||
| 28 | |||
| 29 | #endif // NDEBUG |
||
| 30 | |||
| 31 | #endif //__DEBUG_INCLUDED__ |