-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Invalid ES6->ES5 lowering of static name & length methods #1460
Comments
That would work for ES5, but not ES3. |
(note: for DDC we're only after ES6->ES5 lowering) |
I think ES6 -> ES3 is probably a small minority (except by accident because that's the default). I wonder if we can do an ES6 -> ES5 transpilation early, then do a very late ES5 -> ES3 transpilation at the end. That would allows us to convert things like Object.defineProperty after all the other checks and optimizations were complete. |
…or Closure, to avoid ES5->ES6 lowering bug (google/closure-compiler#1460). This is part of the overall "simple closure" effort (issue #312) BUG= R=jmesserly@google.com Review URL: https://codereview.chromium.org/1630963003 .
…rties) for Closure, to avoid ES5->ES6 lowering bug (google/closure-compiler#1460)." This reverts commit a637e1b.
…or Closure, to avoid ES5->ES6 lowering bug (google/closure-compiler#1460). This is part of the overall "simple closure" effort (issue #312)
…or Closure, to avoid ES5->ES6 lowering bug (google/closure-compiler#1460). This is part of the overall "simple closure" effort (issue #312) BUG= R=jmesserly@google.com Review URL: https://codereview.chromium.org/1630963003 .
…rties) for Closure, to avoid ES5->ES6 lowering bug (google/closure-compiler#1460)." This reverts commit a637e1b048487629d0d44620eb41e703531ce18d.
Function.length and Function.name are not writable, which means the following valid ES6 code is not lowered properly:
Is currently lowered to:
And should be lowered to something like:
(this bug came up in some DDC-compiled Dart code)
The text was updated successfully, but these errors were encountered: