Fix when macro to output all of body

This commit is contained in:
Justin Ethier 2015-07-02 22:27:32 -04:00
parent c8537e0e12
commit 1f1e3f4d59

View file

@ -81,7 +81,7 @@
(if (null? (cdr exp)) (error "empty when" exp)) (if (null? (cdr exp)) (error "empty when" exp))
(if (null? (cddr exp)) (error "no when body" exp)) (if (null? (cddr exp)) (error "no when body" exp))
`(if ,(cadr exp) `(if ,(cadr exp)
((lambda () ,(caddr exp))) ((lambda () ,@(cddr exp)))
#f))) #f)))
(cons 'cond (cons 'cond
(lambda (expr rename compare) (lambda (expr rename compare)