summaryrefslogtreecommitdiff
path: root/sys/include/ape/assert.h
blob: 89e9b6b676b214780d1bf91274dc284c600f16b5 (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) ((e) ? (void)0 : _assert(__FILE__, __LINE__))
#endif /* NDEBUG */