16 lines
838 B
C
16 lines
838 B
C
#ifndef _KERNEL_LIBK_ASSERT_H
|
|
#define _KERNEL_LIBK_ASSERT_H
|
|
|
|
#include <sys/spin.h>
|
|
|
|
#define assert(x) \
|
|
do { \
|
|
if (!(x)) { \
|
|
DEBUG ("%s ssertion failed\n", #x); \
|
|
spin (); \
|
|
__builtin_unreachable (); \
|
|
} \
|
|
} while (0)
|
|
|
|
#endif // _KERNEL_LIBK_ASSERT_H
|