diff code/test.lm @ 3:a9a2ad99adfb

Rework lmc a bit to support labels in generated code. Add support for certain special funcall expressions, namely: if:else, isInteger? value and tail which translate to SEL ATOM CAR and CDR respectively
author Michael Pavone <pavone@retrodev.com>
date Fri, 25 Jul 2014 10:52:17 -0700
parents 71e8d638da5c
children afd55b32549b
line wrap: on
line diff
--- a/code/test.lm	Fri Jul 25 09:32:12 2014 -0700
+++ b/code/test.lm	Fri Jul 25 10:52:17 2014 -0700
@@ -4,6 +4,10 @@
 	}
 	
 	main <- {
-		1 | [(2 + 32 * 8) 3 4]
+		if: (isInteger?: 1 | [(2 + 32 * 8) 3 4]) {
+			42
+		} else: {
+			24
+		}
 	}
 }