Good points, Mark.

There are two better ways forward that I see:

1. Separate forms and make them compose well. Instead of let (x=y){z} and the grammatically unsound let (x=y)x*x from ES4, given let in ES6, and do expressions in ES7, declare victory and use `do { let x = y; z }`.

2. Sweet.js (http://sweetjs.org/), hygienic macros for JS, with syntax-case-strength matching and enforestation magic. http://sweetjs.org/doc/main/sweet.html

We try to follow (1) in TC39. It is why we didn't rush the ?. "null-soaking" operator in. I suspect that (2) deserves a look in about a year, but welcome thoughts from Tim Disney et al (@natefaubion @jlongster).

/be
_______________________________________________
es-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es-discuss

Reply via email to