Intentional breaking change in ES6 draft spec?

Brendan Eich brendan at mozilla.com
Thu Jun 13 17:54:07 PDT 2013


Luke Hoban wrote:
> The ES6 draft grammar no longer allows the following, which was legal ES5:
>
>      for(var i = 1 in []) {}
>
> Was that an intentional breaking change?  If so, why?

Yes, to simplify and tighten up grammar (and engines). We reckoned that 
only testsuites counted on this. This was recorded in some meeting notes 
but I'm not free to dig them up right now.

>    (Of course, there are exceedingly limited practical uses of this, but that alone doesn't seem to justify a breaking change).

We had some web crawling help, IIRC. We also figured we had time to test 
and put it back, if needed. Did you find web content using it?

/be


More information about the es-discuss mailing list