23 lines
481 B
C
23 lines
481 B
C
#pragma once
|
|
|
|
#include <rt/atomic.h>
|
|
|
|
#include <stdbool.h>
|
|
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif
|
|
|
|
void rt_assert(bool condition, const char *msg);
|
|
|
|
#if defined(__cplusplus) || \
|
|
(defined(__STDC_VERSION__) && (__STDC_VERSION__ >= 202311L))
|
|
#define rt_static_assert(condition, msg) static_assert(condition, msg)
|
|
#else
|
|
#define rt_static_assert(condition, msg) _Static_assert(condition, msg)
|
|
#endif
|
|
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif
|