Block Lambdas: break and continue
Brendan Eich
brendan at mozilla.org
Mon Jan 16 11:09:10 PST 2012
With completion values as In ES1-5, not even depending on
http://wiki.ecmascript.org/doku.php?id=harmony:completion_reform, it
might be enough to say:
foo {||
exit: {
...
if (...) {
"early";
break exit;
}
...
}
}
IINM this would work. Sugaring it using 'with' looks nice -- always
tempting to re-use 'with'.
I have some angst about loss of a hunk of code running "break L" up
against " with (E)\nS" where E is an expression and S is a statement and
the two came from a bone-fide with statement later in the unmangled source.
/be
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/es-discuss/attachments/20120116/4b1e3c15/attachment.html>
More information about the es-discuss
mailing list