-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
PropertyName doesn't inherit Yield in AssignmentProperty #388
Comments
Generally properties can have any keyword name (e.g., return, throw, to take a couple examples used in primordials) so I think this is fine. |
@littledan I believe the grammar says function *g() {
({[yield]: x} = y);
} would not be a valid program, but will become valid if this flag is added. 👍 This change sounds good. |
yup looks likes like an oversight in the ES6 grammar. |
Oh I see, my mistake. |
Resolves issue tc39#388.
(Following up on #374 (comment) ...)
In the production
I'm wondering why
PropertyName
isn'tPropertyName[?Yield]
. Everywhere else that PropertyName appears, it inherits the setting of the Yield parameter.I've looked at other places in the grammar where a nonterminal could inherit a parameter-setting but doesn't, and I could generally see why, but not in this case.
And I looked in test262 and didn't find a test that would distinguish the two possibilities.
So I'm thinking it's maybe a bug.
The text was updated successfully, but these errors were encountered: