aboutsummaryrefslogtreecommitdiffstats
path: root/csc/ir2.csc
diff options
context:
space:
mode:
authorRose Hogenson <rhogenson@posteo.net>2022-07-29 16:42:27 -0700
committerRose Hogenson <rhogenson@posteo.net>2022-07-29 16:42:27 -0700
commit0ddb8fb300b916605baa2552eec3dc77b4e6e154 (patch)
treea4c9bf70efcf8a950f2e85ecb22b9094e791ca63 /csc/ir2.csc
parent6521edcf224b7e044e9fa42a6f9c92fcf738cb34 (diff)
downloadchromatopelma-0ddb8fb300b916605baa2552eec3dc77b4e6e154.tar.zst
Fix some compilation errors in the compiler.
Diffstat (limited to 'csc/ir2.csc')
-rw-r--r--csc/ir2.csc14
1 files changed, 14 insertions, 0 deletions
diff --git a/csc/ir2.csc b/csc/ir2.csc
index 4e4c42e..800d3c0 100644
--- a/csc/ir2.csc
+++ b/csc/ir2.csc
@@ -7,8 +7,10 @@
%globals
%label
%primitive
+ %tail
%variable
*globals*
+ *tail*
apply-arguments
apply-procedure
apply?
@@ -43,6 +45,7 @@
primitive-operation
primitive-results
primitive?
+ tail?
variable-gensym
variable?
@@ -180,6 +183,17 @@
(arguments apply-arguments))
+ ; The tail continuation. Used for the exit point of library init functions,
+ ; and the end of a program.
+ (define-match-record-type <tail>
+ (make-tail)
+ tail?
+ %tail)
+
+
+ (define *tail* (make-tail))
+
+
; A procedure. All closures are allocated in a fix expression. A closure
; does not take a continuation. Instead, the procedure will accept the
; continuation as an argument.