Skip to content

Evaluate RHS of binding/assignment pattern first #34806

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

Merged
merged 1 commit into from
Oct 30, 2019
Merged

Evaluate RHS of binding/assignment pattern first #34806

merged 1 commit into from
Oct 30, 2019

Conversation

rbuckton
Copy link
Contributor

This forces caching the destructured variable prior to evaluating non-literal-valued computed property names in a binding or assignment pattern. We only cache up front when we detect non-literal-valued computed property names so that we can avoid emitting excessive temporary variables.

Fixes #32305

@rbuckton
Copy link
Contributor Author

CC: @RyanCavanaugh, @weswigham, @sandersn

Copy link
Member

@sandersn sandersn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some optional style suggestions.

@rbuckton rbuckton merged commit 87cc8c4 into master Oct 30, 2019
@rbuckton rbuckton deleted the fix32305 branch December 16, 2019 22:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Destructuring breaks program order
2 participants