Fix inlining of lambda-apply-lambda.
authorAndy Wingo <wingo@pobox.com>
Sun, 28 Mar 2010 12:31:57 +0000 (14:31 +0200)
committerAndy Wingo <wingo@pobox.com>
Sun, 28 Mar 2010 12:31:57 +0000 (14:31 +0200)
* module/language/tree-il/inline.scm (inline!): Only inline (lambda args
  (apply (lambda ...) args)) if the outer lambda has rest args. Thanks
  to Mark Weaver for the note.

module/language/tree-il/inline.scm

index 4e3863ef6710ad898028f9847ce822959207d856..8dd7dd334f29b7ae0c1bc6a8640235a3341bb974 100644 (file)
              (lp (cdr args) (cdr vars)))
             (else #f))))
          
-       (and (not opt) (not kw) (not alternate)
+       (and (not opt) (not kw) rest (not alternate)
             (record-case body
               ((<application> proc args)
                ;; (lambda args (apply (lambda ...) args)) => (lambda ...)