summaryrefslogtreecommitdiff
path: root/sys/include/ape/assert.h
blob: 40c26102c80d33c83df1cf19a7d1d1ebebdf46f7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#pragma lib "/$M/lib/ape/libap.a"

#undef assert
#ifdef NDEBUG
#define assert(ignore) ((void)0)
#else
#ifdef __cplusplus
extern "C" {
#endif

extern void _assert(char *, unsigned);

#ifdef __cplusplus
}
#endif
#define assert(e) {if(!(e))_assert(__FILE__, __LINE__);}
#endif /* NDEBUG */