From 952250b6d79063aa1066b0e945d58360bd70d09f Mon Sep 17 00:00:00 2001 From: Mel Date: Wed, 6 May 2026 18:49:26 +0200 Subject: Lowering pass test harness, and initial pass test suite Signed-off-by: Mel --- boot/tests/lower/simple_var.cskt | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 boot/tests/lower/simple_var.cskt (limited to 'boot/tests/lower/simple_var.cskt') diff --git a/boot/tests/lower/simple_var.cskt b/boot/tests/lower/simple_var.cskt new file mode 100644 index 0000000..b1b0c92 --- /dev/null +++ b/boot/tests/lower/simple_var.cskt @@ -0,0 +1,26 @@ +a single typed variable declaration with an integer initializer +inside the body of `main`. + +<<< + +main = fun () { + var x int = 5 +} + +>>> + +(unit + (types + (type 0 int primitive) + (type 1 uint primitive) + (type 2 bool primitive) + (type 3 string primitive) + (type 4 float primitive) + (type 5 byte primitive) + (type 6 ascii primitive) + (type 7 void primitive)) + (functions + (function 0 main main (returns (ref void)) (block + (declaration x (ref int) (initializer (expr 5))) + ))) + (emission_order 0 1 2 3 4 5 6 7)) \ No newline at end of file -- cgit 1.4.1