-
Notifications
You must be signed in to change notification settings - Fork 150
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
Issue with arrow
and a specific syntax
#259
Labels
Comments
nene
added a commit
that referenced
this issue
Sep 14, 2017
The second tests fails, so marking it as skipped. Expecting that it's a bug in Recast. Refs #259
Thanks for reporting. I see that the transform works without crashing, but results in invalid JavaScript: var a = b => {
a: 1,
b: 2,
}[a]; it really should be: var a = b => ({
a: 1,
b: 2,
}[a]); Seems to be a bug in Recast library that handles turning the transformed AST back to code. It has a history of bugs related to the placement of parentheses. |
Recast has on open bug for a very similar-looking issue: benjamn/recast#351 |
Closed
nene
added a commit
that referenced
this issue
Sep 12, 2018
Recent upgrade of Recast has fixed it. Refs #259
Fixed in 3.0.2 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I think the following syntax causes a bug with the
arrow
transform:More specifically the
[b]
after thereturn
seems to be the cause of it.The text was updated successfully, but these errors were encountered: