From 3bcf956a29ac85a7a37e6e3252bf3238c8729856 Mon Sep 17 00:00:00 2001 From: Justin Ethier Date: Tue, 17 May 2016 00:26:04 -0400 Subject: [PATCH] WIP --- scheme/cyclone/cps-optimizations.sld | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/scheme/cyclone/cps-optimizations.sld b/scheme/cyclone/cps-optimizations.sld index e1ce006f..733a6bcb 100644 --- a/scheme/cyclone/cps-optimizations.sld +++ b/scheme/cyclone/cps-optimizations.sld @@ -25,6 +25,7 @@ (scheme cyclone transforms) (srfi 69)) (export + optimize-cps analyze-cps opt:contract ;adb:init! @@ -237,9 +238,11 @@ (ast:%make-lambda (ast:lambda-id exp) (ast:lambda-args exp) - (ast:lambda-body exp)));) - ((ref? exp) exp) + (opt:contract (ast:lambda-body exp))));) ((const? exp) exp) + ((ref? exp) exp) + ((prim? exp) exp) + ((quote? exp) exp) ((define? exp) `(define ,(opt:contract (define->var exp)) ,(opt:contract (define->exp exp)))) @@ -261,7 +264,7 @@ ) (define (optimize-cps ast) - (analyze-cps input-program) + (analyze-cps ast) (trace:info "---------------- cps analysis db:") (trace:info (adb:get-db)) (opt:contract ast)