From 31e99da29586f4a9f9390d6ca93da31e86fc3eb4 Mon Sep 17 00:00:00 2001 From: Justin Ethier Date: Wed, 26 Sep 2018 12:25:08 -0400 Subject: [PATCH] Bugfix - swap when we use num-lambda --- scheme/cyclone/cgen.sld | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scheme/cyclone/cgen.sld b/scheme/cyclone/cgen.sld index d14af789..e9d5bf62 100644 --- a/scheme/cyclone/cgen.sld +++ b/scheme/cyclone/cgen.sld @@ -906,7 +906,7 @@ ;;TODO: this is not going to work, we are going to need to use ast:lambda-id instead of ;;an allocation ID. make that change in allocate-lambda, disable all WKL code, and make ;;sure it is stable before proceeding... -; cgen id ,(adbf:cgen-id fnc) +; cgen id ,(ast:lambda-id wkf) ; ))) ; ) (set-c-call-arity! (c:num-args cargs)) @@ -1160,7 +1160,7 @@ (define (allocate-lambda ast:lam lam . cps?) (let ((id num-lambdas)) (cond - ((and ast:lam (equal? cps? '(#f))) + ((and ast:lam (not (equal? cps? '(#f)))) (set! id (ast:lambda-id ast:lam))) (else (set! num-lambdas (+ 1 num-lambdas))))