diff options
author | elioat <elioat@tilde.institute> | 2025-01-19 15:08:04 -0500 |
---|---|---|
committer | elioat <elioat@tilde.institute> | 2025-01-19 15:08:04 -0500 |
commit | c33abea4005922736c1d9a8b4891b3acc79288b3 (patch) | |
tree | a7b6a5ac458248765300760ad0a18650f16b796f /awk/scheme | |
parent | 377afbf02b5969df9481af39ea7a11fe0c39b18d (diff) | |
download | tour-c33abea4005922736c1d9a8b4891b3acc79288b3.tar.gz |
*
Diffstat (limited to 'awk/scheme')
-rwxr-xr-x | awk/scheme/scheme/bin/compiler.awk | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/awk/scheme/scheme/bin/compiler.awk b/awk/scheme/scheme/bin/compiler.awk index b1a2a10..d4d0ff0 100755 --- a/awk/scheme/scheme/bin/compiler.awk +++ b/awk/scheme/scheme/bin/compiler.awk @@ -214,6 +214,14 @@ function compile_primitive_call(op, args, arg_array, nargs, i) { if (nargs != 1) error("cdr requires 1 argument") print "CDR" } + else if (op == "<") { + if (nargs != 2) error("< requires 2 arguments") + print "LT" + } + else if (op == "=") { + if (nargs != 2) error("= requires 2 arguments") + print "EQ" + } else { error("Unknown operator: " op) } |