abouttreesummaryrefslogcommitdiff
path: root/src/fixedbuffer.h
diff options
context:
space:
mode:
authorPatrick2023-05-16 17:03:50 +0200
committerPatrick2023-05-16 17:03:50 +0200
commit7cba6b3cdbd3b82ec9092ce9bda8ec20739096cb (patch)
tree3a634529c1bee00d2ea98f7d42d9b8cfca6a1410 /src/fixedbuffer.h
parentd43e8671acc5709c192e159e0d91626f0677cdf1 (diff)
downloadmatrix_esp_thesis-7cba6b3cdbd3b82ec9092ce9bda8ec20739096cb.tar.gz
matrix_esp_thesis-7cba6b3cdbd3b82ec9092ce9bda8ec20739096cb.zip
refactor fixedbuffer, add mjson
Diffstat (limited to 'src/fixedbuffer.h')
-rw-r--r--src/fixedbuffer.h19
1 files changed, 19 insertions, 0 deletions
diff --git a/src/fixedbuffer.h b/src/fixedbuffer.h
new file mode 100644
index 0000000..d8055cb
--- /dev/null
+++ b/src/fixedbuffer.h
@@ -0,0 +1,19 @@
+#ifndef FIXEDBUFFER__H
+#define FIXEDBUFFER__H
+
+#include <stdbool.h>
+
+typedef struct FixedBuffer {
+ char * ptr;
+ int cap;
+ int len;
+} FixedBuffer;
+
+FixedBuffer
+FixedBuf(const char * str);
+
+bool
+FixedBufferToInt(FixedBuffer fb, int * outInt);
+
+
+#endif \ No newline at end of file