(and-let*): Give #t for an empty body, per srfi-2
authorKevin Ryde <user42@zip.com.au>
Wed, 25 Aug 2004 00:46:59 +0000 (00:46 +0000)
committerKevin Ryde <user42@zip.com.au>
Wed, 25 Aug 2004 00:46:59 +0000 (00:46 +0000)
spec, previously came out as an empty (begin).

ice-9/and-let-star.scm

index 9bd01d1..6604df1 100644 (file)
@@ -25,7 +25,9 @@
   (define (expand vars body)
     (cond
      ((null? vars)
-      `(begin ,@body))
+      (if (null? body)
+         #t
+         `(begin ,@body)))
      ((pair? vars)
       (let ((exp (car vars)))
         (cond