On 1 June 2012 00:28, Brendan Eich <[email protected]> wrote:

> In the with example that Dave gave:
>
>    with (obj) {
>        foo() // no semi
>        .bar = 12
>    }
>
>
> it's all allowed as in no syntax error (to correct via ASI) and no
> restricted production (to make line termination significant).
>
> Over the years people have suggested reforming 'with' a la VB by requiring
> leading . before names meant to be looked up in the 'with' object instead
> of the scope chain. But that fails as Dave showed.
>
> T.J. was suggesting that Dave's cascade proposal has the 'with' hazard,
> but it doesn't. No scope chain lookup. Therefore no need for leading ., ~.
> or any such noise.
>
> /be
>
>
What is "Dave's cascade proposal"? You mean throwing function calls into
the existing object extension literal? Or...?

I'd appreciate it if characterizations like "noise" were done...carefully.
We're all here because we love JS and want to improve it and move it
forward.

Thanks,

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

Reply via email to