Fill in missing builtin lambda info
authorLuke Lau <luke_lau@icloud.com>
Sat, 27 Jul 2019 23:04:36 +0000 (00:04 +0100)
committerLuke Lau <luke_lau@icloud.com>
Sat, 27 Jul 2019 23:04:36 +0000 (00:04 +0100)
codegen.scm

index 517cc110e545d9fe3490b0eeaf5c5d35b2c3d375..4e05bcf797b31d175a9629aac4b75868bbd9c72e 100644 (file)
       ('+ "_add")
       ('- "_sub")
       ('* "_mul")
+      ('! "_not")
+      ('= "_eq")
       ('bool->int "_bool2int")
-      (else (error #f "fill this out"))))
+      ('print "_print")
+      (else (error #f "don't know this builtin"))))
   (define (builtin-args e)
     (case e
       ('+ '(x y))
       ('- '(x y))
       ('* '(x y))
+      ('! '(x))
+      ('= '(x y))
       ('bool->int '(x))
-      (else (error #f "fill this out"))))
+      ('print '(x))
+      (else (error #f "don't know this builtin"))))
 
   (define (add-builtin-lambda e)
     (let* [(label (builtin-name e))