From: David Vázquez Date: Fri, 5 Jul 2013 02:48:08 +0000 (+0200) Subject: Migrate MULTIPLE-VALUE-PROG1 X-Git-Url: http://repo.macrolet.net/gitweb/?a=commitdiff_plain;h=e59357386912300037967407f24f85098f557fb5;p=jscl.git Migrate MULTIPLE-VALUE-PROG1 --- diff --git a/src/compiler.lisp b/src/compiler.lisp index 57248f7..9ff6cd7 100644 --- a/src/compiler.lisp +++ b/src/compiler.lisp @@ -919,10 +919,13 @@ `(return (call (get func "apply") |window| args)))))) (define-compilation multiple-value-prog1 (first-form &rest forms) - (js!selfcall - "var args = " (ls-compile first-form *multiple-value-p*) ";" - (ls-compile-block forms) - "return args;" )) + (js!selfcall* + `(var (args ,(ls-compile first-form *multiple-value-p*))) + ;; TODO: Interleave is temporal + `(progn ,@(interleave (mapcar #'ls-compile forms) + '(code ";") + t)) + `(return args))) (define-transformation backquote (form) (bq-completely-process form))