summaryrefslogtreecommitdiff
path: root/kon/konsave.h
diff options
context:
space:
mode:
authorKonAki <konaki@anokonaki.org>2026-10-13 10:28:17 +0800
committerKonAki <konaki@anokonaki.org>2026-10-13 10:28:17 +0800
commitd3432fcc288a53dff9eb219c8857ca48c5981323 (patch)
treefba5cc730c91d2c674efe6d71dd20e9d6bf7d0d8 /kon/konsave.h
parenta2dc5ca4c659e2d0a9527cd0910bc76b65e6d09f (diff)
headers: extern C guards and C++ safe vector and rect constructors
Diffstat (limited to 'kon/konsave.h')
-rw-r--r--kon/konsave.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/kon/konsave.h b/kon/konsave.h
index 45e45c1..9bfe649 100644
--- a/kon/konsave.h
+++ b/kon/konsave.h
@@ -29,6 +29,10 @@
#include <stddef.h>
#include <stdint.h>
+#ifdef __cplusplus
+extern "C" {
+#endif
+
/*** definition ***/
/* a save is a list of tagged chunks, so each part of a game writes and reads its own and a menu can read just
@@ -96,4 +100,8 @@ int kon_saveWriteFile(const char *path, const void *buf, size_t len);
/* how many bytes were read, or -1 if it could not be opened or does not fit in cap */
long kon_saveReadFile(const char *path, void *buf, size_t cap);
+
+#ifdef __cplusplus
+}
+#endif
#endif /* KONSAVE_H */