[parenscript-devel] Bug: cases where PS generates syntax errors instead of expressions
Vladimir Sedach
vsedach at gmail.com
Mon Dec 12 23:47:09 UTC 2011
I've pushed a patch that fixes both the object literal and top-level
lambda printing. Let me know if you see anything else broken.
Vladimir
On Mon, Nov 7, 2011 at 5:15 PM, Daniel Gackle <danielgackle at gmail.com> wrote:
> (ps (create a 11 b 22)) => "{ a : 11, b : 22 };", which is illegal at
> the top level because JS interprets the curly braces as statement
> block delimiters. PS should probably generate "({ a : 11, b : 22 })"
> instead.
>
> Similarly, (ps (lambda () 123)) =>
>
> "function () {
> return 123;
> };"
>
> is also illegal at the top level and should also be wrapped in parens.
>
> Such forms obviously don't come up much in source files, but they do
> in a REPL. We're making a PS REPL (and source-level debugger) for
> Emacs, which is how we ran across them.
>
> _______________________________________________
> 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