[parenscript-devel] Function application and variable renaming

Vladimir Sedach vsedach at gmail.com
Sat Jan 7 20:05:42 UTC 2012


Yes, Parenscript tries to pretend to be a Lisp-2 in lexical contexts
where it's obvious what's going on. The only time that this can fail
(that I can think of) is for global variables.

Vladimir

On Fri, Jan 6, 2012 at 3:11 PM, Scott Bell <scott at skysheet.com> wrote:
> PS appears not to support Lisp-1-style function application in the
> presence of variable renaming:
>
> (ps (let ((a 10))
>        (let ((a (lambda () 17)))
>          (a))))
>
> =>
>
> "(function () {
>    var a = 10;
>    var a1 = function () {
>        return 17;
>    };
>    return a();
> })();"
>
> If I use FUNCALL, or even FLET instead of LET, the correct code
> is generated. There's obviously some Lisp-2 action going on in PS,
> but unless I'm mistaken it seems like both forms can be supported.
>
>    Scott
>
> _______________________________________________
> parenscript-devel mailing list
> parenscript-devel at common-lisp.net
> http://lists.common-lisp.net/cgi-bin/mailman/listinfo/parenscript-devel




More information about the parenscript-devel mailing list