summaryrefslogtreecommitdiff
path: root/scripts/dietc_helpers.h
diff options
context:
space:
mode:
authorMatthew Sotoudeh <matthew@masot.net>2023-07-25 14:58:33 -0700
committerMatthew Sotoudeh <matthew@masot.net>2023-07-25 14:58:33 -0700
commit1d943da0cf9154e7ce78ce867cdbb91531c5d78e (patch)
tree40c5c6c3ba7fafa6567aa5b5aa216caecf3935fc /scripts/dietc_helpers.h
initial dietc commit
Diffstat (limited to 'scripts/dietc_helpers.h')
-rw-r--r--scripts/dietc_helpers.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/scripts/dietc_helpers.h b/scripts/dietc_helpers.h
new file mode 100644
index 0000000..a5e00ac
--- /dev/null
+++ b/scripts/dietc_helpers.h
@@ -0,0 +1,5 @@
+extern void *memset(void *, int, long unsigned int);
+#define BINARY(a, op, b) a op b
+#define PTR_BINARY(a, op, b) ((void*)(a) op (unsigned long)(b))
+#define MEMZERO(obj) memset(&obj, 0, sizeof(obj))
+#define FIELDPTR(sptr, field) (&(sptr -> field))
generated by cgit on debian on lair
contact matthew@masot.net with questions or feedback