In current version, this works just fine:

    var let = 6;

That could work with let being a contextual keyword.

But how about:

    var a = 5;
    let(a = 6)
    {
        alert(a)
    }

Currently that does:

    var a = 5;
    a = 6;
    let(6);
    //purposeless block
    {
        alert(a);
    }

But if interpreted in ES6 the meaning changes completely.

The above snippets only cause syntax errors in strict mode but work fine in non-strict.

How is this resolved? Will ES6 require some kind of opt-in in a script tag?
_______________________________________________
es-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es-discuss

Reply via email to