From c5fcc7d0f5c3f2f596f4d02d5e84283efce7eb52 Mon Sep 17 00:00:00 2001 From: Rose Hogenson Date: Tue, 21 Jun 2022 20:14:25 -0700 Subject: More progress on CPS. --- csc/cps.csc | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'csc/cps.csc') diff --git a/csc/cps.csc b/csc/cps.csc index 561a698..bd4f088 100644 --- a/csc/cps.csc +++ b/csc/cps.csc @@ -1,16 +1,19 @@ (define-library (csc cps) + (export + ir1->ir2) (import (only (csc ir1) make-constant constant? lexical-ref? library-ref?) (only (csc ir2) - (make-atom)) + make-atom + make-tail) (scheme base)) (begin - (define (to-cps expr k) + (define (to-cps expr continuation) (cond ((or (constant? expr) (lexical-ref? expr) @@ -20,3 +23,4 @@ (define (ir1->ir2 program) + (to-cps program (make-tail))))) -- cgit v1.3.1