shithub: femtolisp

Download patch

ref: c076be667bfd617bf0cfe8e9ea690a1632651c38
parent: 4cb9685266101394b296053de8957ce9407cfe77
author: JeffBezanson <jeff.bezanson@gmail.com>
date: Thu Mar 26 23:47:11 EDT 2009

fixing bug in macroexpand on lambdas


--- a/femtolisp/system.lsp
+++ b/femtolisp/system.lsp
@@ -111,6 +111,10 @@
 	      (if f
 		  (macroexpand-in (apply f (cdr e)) env)
 		  (cond ((eq (car e) 'quote) e)
+			((eq (car e) 'lambda)
+			 (nlist* 'lambda (cadr e)
+				 (macroexpand-in (caddr e) env)
+				 (cdddr e)))
 			((eq (car e) 'let-syntax)
 			 (let ((binds (cadr e))
 			       (body  (f-body (cddr e))))