summaryrefslogtreecommitdiff
path: root/base.h
diff options
context:
space:
mode:
authorLeo Tenenbaum <pommicket@gmail.com>2020-11-20 16:58:59 -0500
committerLeo Tenenbaum <pommicket@gmail.com>2020-11-20 16:58:59 -0500
commitc3fd9dfa23969c842991da4cd852330288889463 (patch)
tree1a2e390ae57109febea9a5853ef9f04559d1f820 /base.h
parentc376f6f53f737d6220206baa323c0bc62d48a9f0 (diff)
started text rendering
Diffstat (limited to 'base.h')
-rw-r--r--base.h37
1 files changed, 37 insertions, 0 deletions
diff --git a/base.h b/base.h
new file mode 100644
index 0000000..92270bc
--- /dev/null
+++ b/base.h
@@ -0,0 +1,37 @@
+#ifndef BASE_H_
+#define BASE_H_
+
+#include <stdbool.h>
+#include <stdint.h>
+#include <stdio.h>
+#include <stddef.h>
+
+typedef uint8_t u8;
+typedef uint16_t u16;
+typedef uint32_t u32;
+typedef uint64_t u64;
+
+typedef int8_t i8;
+typedef int16_t i16;
+typedef int32_t i32;
+typedef int64_t i64;
+
+typedef unsigned int uint;
+typedef unsigned long ulong;
+
+#ifdef __GNUC__
+#define no_warn_start _Pragma("GCC diagnostic push") \
+ _Pragma("GCC diagnostic ignored \"-Wpedantic\"") \
+ _Pragma("GCC diagnostic ignored \"-Wsign-conversion\"") \
+ _Pragma("GCC diagnostic ignored \"-Wsign-compare\"") \
+ _Pragma("GCC diagnostic ignored \"-Wconversion\"") \
+ _Pragma("GCC diagnostic ignored \"-Wimplicit-fallthrough\"") \
+ _Pragma("GCC diagnostic ignored \"-Wunused-function\"")
+
+#define no_warn_end _Pragma("GCC diagnostic pop")
+#else
+#define no_warn_start
+#define no_warn_end
+#endif
+
+#endif