#ifndef _KERNEL_LIBK_ASSERT_H
#define _KERNEL_LIBK_ASSERT_H

#include <sys/debug.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
