• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 #ifdef __ICCARM__ /* for iar */
2 #include_next <assert.h>
3 #else
4 #include <features.h>
5 
6 #undef assert
7 
8 #ifdef NDEBUG
9 #define	assert(x) (void)0
10 #else
11 #define assert(x) ((void)((x) || (__assert_fail(#x, __FILE__, __LINE__, __func__),0)))
12 #endif
13 
14 #if __STDC_VERSION__ >= 201112L && !defined(__cplusplus)
15 #define static_assert _Static_assert
16 #endif
17 
18 #ifdef __cplusplus
19 extern "C" {
20 #endif
21 
22 _Noreturn void __assert_fail (const char *, const char *, int, const char *);
23 
24 #ifdef __cplusplus
25 }
26 
27 #endif /* __ICCARM__ */
28 #endif
29