about summary refs log tree commit diff
path: root/boot/tests/transpile/basic.cskt
diff options
context:
space:
mode:
Diffstat (limited to 'boot/tests/transpile/basic.cskt')
-rw-r--r--boot/tests/transpile/basic.cskt16
1 files changed, 12 insertions, 4 deletions
diff --git a/boot/tests/transpile/basic.cskt b/boot/tests/transpile/basic.cskt
index eb22b84..5844f94 100644
--- a/boot/tests/transpile/basic.cskt
+++ b/boot/tests/transpile/basic.cskt
@@ -1,7 +1,9 @@
-the transpiler has to follow a simple pattern of
-the files it creates to make viable c source.
-here we check that the simplest possible file has
-all of the expected parts needed.
+smoke test for the ir-driven transpiler: every translation
+unit starts with the core preamble, optionally declares types
+(forward + full def in topological order), then forward-decls
+all functions, then bodies, then the runtime trailer when a
+`main` is present. `main` is renamed to `catskill_main` so the
+runtime can wrap it.
 
 <<<
 
@@ -9,3 +11,9 @@ main = fun () {
 }
 
 >>>
+
+#include "core.c"
+void catskill_main(void);
+void catskill_main(void) {
+}
+#include "runtime.c"