aboutsummaryrefslogtreecommitdiff
path: root/bootstrap/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'bootstrap/main.c')
-rw-r--r--bootstrap/main.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/bootstrap/main.c b/bootstrap/main.c
new file mode 100644
index 0000000..4acf913
--- /dev/null
+++ b/bootstrap/main.c
@@ -0,0 +1,14 @@
+#include "all.h"
+
+int
+main(int argc, char **argv) {
+ struct parser P;
+ struct transunit tu = {0};
+
+ assert(argc > 1);
+ inittypes();
+ initparser(&P, argv[1]);
+ parse(&tu, &P);
+ // dumptransunit(&tu);
+ cgen(stdout, &tu);
+}