summaryrefslogtreecommitdiff
path: root/src/platform/file.h
diff options
context:
space:
mode:
authorJoshua Rowe <17525998+omnisci3nce@users.noreply.github.com>2024-02-25 13:50:16 +1100
committerGitHub <noreply@github.com>2024-02-25 13:50:16 +1100
commitb5b7cea24c46d28a4b72bc18ca8ccb2d532007d3 (patch)
treefe49ddad815c65ef0deb87dd76e172051e6c49e7 /src/platform/file.h
parentfc287c6e4f958242a4272da5cb1704e3e789fe07 (diff)
parent938f745f052c14fccaa987b98ea4ac84e70c1fcc (diff)
Merge pull request #3 from omnisci3nce/feature/some-string-utils
Port String utils but using arena for allocation
Diffstat (limited to 'src/platform/file.h')
-rw-r--r--src/platform/file.h10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/platform/file.h b/src/platform/file.h
index b965ceb..8bb22c8 100644
--- a/src/platform/file.h
+++ b/src/platform/file.h
@@ -6,6 +6,14 @@
*/
#pragma once
-#include <stdbool.h>
+#include "defines.h"
+#include "str.h"
+
+typedef struct str8_opt {
+ str8 contents;
+ bool has_value;
+} str8_opt;
const char* string_from_file(const char* path);
+
+str8_opt str8_from_file(arena* a, str8 path); \ No newline at end of file