Closed Bug 950547 (es6:let) Opened 7 years ago Closed 4 years ago
Make let and const ES6-compatible
According to the ECMAScript 6 support in Mozilla table, many features (let, const, yield,...) do not work as they do in ES6.
Since ES6 is nearing its completion it'd be worth it to make const and let implementation match the spec, especially that: 1) const/let are publicly available in Firefox so having them not following the spec can lead to bugs 2) IE11 has almost correct implementation, Chrome a little worse but still does most things right. const is especially non-conforming with its incorrect function scope.
Status: UNCONFIRMED → NEW
Ever confirmed: true
Summary: Many Mozilla extensions are not compatible to ES6 draft: let, const, destructuring assignment, yield → Make let, const, destructuring assignment, yield ES6-compatible
Actually, you're both right. The bug reported here: https://connect.microsoft.com/IE/feedback/details/805843/there-shoild-be-fresh-let-bindings-created-for-every-loop-iteration is a known issue that was thought to have been implemented correctly because the semantics for per-iteration let bindings had not been finalized. So when IE11 shipped, there was no definitive word on those semantics, so it was in compliant. Those semantics have been defined since then and the implementation is no longer 100%, but Brian Terlson (MS, Chakra team) has assured that it will be fixed. That's the risk of implementing early, and we should definitely applaud the Chakra team for taking that risk :)
(In reply to Rick Waldron [:rwaldron] from comment #4) > That's the risk of implementing early, and we should definitely applaud the > Chakra team for taking that risk :) I was too quick in making fun of them. You're right, I apologize. I do definitely applaud them for taking the risk!
Yield in function* is ES6-compatible. There may be bugs, but they don't merit this tracker.
Summary: Make let, const, destructuring assignment, yield ES6-compatible → Make let, const, destructuring assignment ES6-compatible
At the JS work week, Shu volunteered to work on ES6 let/const assignment. jorendorff says this bug blocks ES6 modules bug 568953.
You could remove the mention of destructuring in favor of bug 1055984, if you like.
Summary: Make let, const, destructuring assignment ES6-compatible → Make let and const ES6-compatible
It seems that `const` is 100% spec compliant in Spidermonkey 44 now. Is that correct?
No. Bug 449811, bug 1069480, and other for-in/of bugs are still relevant and require fixing for the cast of const, not just for the case of let. (And in general see the full dependency tree to see what other things still need work.)
Fixed by bug 1263355.
Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.