X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fcompiler%2Flocall.lisp;h=9e605c1e430d836f983b022c262483120f44040e;hb=d94c1b4a8c534bde146823f56558faf37cd4c4d7;hp=b6d52c2e9c986bd2ea210a725c387429d2609ff9;hpb=edb7acf8d242c0398ec33924e21c85dc54bc768d;p=sbcl.git diff --git a/src/compiler/locall.lisp b/src/compiler/locall.lisp index b6d52c2..9e605c1 100644 --- a/src/compiler/locall.lisp +++ b/src/compiler/locall.lisp @@ -683,6 +683,22 @@ (call-args t))) (:rest (call-args `(list ,@more-temps)) + ;; &REST arguments may be accompanied by extra + ;; context and count arguments. We know this by + ;; the ARG-INFO-DEFAULT. Supply NIL and 0 or + ;; don't convert at all depending. + (let ((more (arg-info-default info))) + (when more + (unless (eq t more) + (destructuring-bind (context count &optional used) more + (declare (ignore context count)) + (when used + ;; We've already converted to use the more context + ;; instead of the rest list. + (return-from convert-more-call)))) + (call-args nil) + (call-args 0) + (setf (arg-info-default info) t))) (return)) (:keyword (return)))