summaryrefslogtreecommitdiff
path: root/base.h
diff options
context:
space:
mode:
Diffstat (limited to 'base.h')
-rw-r--r--base.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/base.h b/base.h
index c2cd80d..8994daf 100644
--- a/base.h
+++ b/base.h
@@ -32,6 +32,12 @@
#include <assert.h>
#include <uchar.h>
+#if !__TINYC__ && __STDC_VERSION__ >= 201112
+#define static_assert_if_possible(cond) _Static_assert(cond, "Static assertion failed");
+#else
+#define static_assert_if_possible(cond)
+#endif
+
typedef uint8_t u8;
typedef uint16_t u16;
typedef uint32_t u32;