Fix linux build.
[reactos.git] / irc / ArchBlackmann / verify.h
1 // verify.h
2 // This code is (C) 2003-2004 Royce Mitchell III
3 // and released under the LGPL & BSD licenses
4
5 #ifndef VERIFY_H
6 #define VERIFY_H
7
8 //#include <assert.h>
9
10 #ifdef ASSERT
11 #undef ASSERT
12 #endif//ASSERT
13
14 #include "panic.h"
15
16 #if defined(DEBUG) || defined(_DEBUG)
17 inline void AssertHandler ( bool b, const char* str )
18 {
19 if ( !b )
20 panic ( str );
21 }
22 # define ASSERT(x) AssertHandler((x) ? true : false, #x )
23 #else
24 # define ASSERT(x)
25 #endif
26
27 #ifdef verify
28 #undef verify
29 #endif//verify
30
31 #if defined(DEBUG) || defined(_DEBUG)
32 # define verify(x) ASSERT(x)
33 #else
34 # define verify(x) x
35 #endif
36
37 #endif//VERIFY_H