start with c codegen
[ccc.git] / util.h
diff --git a/util.h b/util.h
index 79d12d8..47677a8 100644 (file)
--- a/util.h
+++ b/util.h
@@ -3,6 +3,7 @@
 
 #include <stdarg.h>
 #include <stdbool.h>
+#include <stdio.h>
 
 struct list { void *el; struct list *tail; };
 struct list *list_cons(void *el, struct list *tail);
@@ -24,5 +25,7 @@ void pindent(int indent, FILE *out);
 void safe_fprintf(FILE *out, const char *msg, ...);
 void *safe_malloc(size_t size);
 void *safe_strdup(const char *c);
+FILE *safe_fopen(const char *path, const char *mode);
+void safe_fclose(FILE *file);
 
 #endif