Skip to content
This repository has been archived by the owner on Jan 19, 2019. It is now read-only.

Support TSParenthesizedExpression #464

Closed
ikatyang opened this issue Apr 9, 2018 · 2 comments
Closed

Support TSParenthesizedExpression #464

ikatyang opened this issue Apr 9, 2018 · 2 comments
Labels

Comments

@ikatyang
Copy link
Contributor

ikatyang commented Apr 9, 2018

What version of TypeScript are you using?
2.8.1

What version of typescript-eslint-parser are you using?
14.0.0

What code were you trying to parse?

var newArray = /** @type {Array} */ (numberOrString).map(x => x);

What did you expect to happen?
TSParenthesizedExpression should exist since it's used by TypeScript's checkJS mode, see also prettier/prettier#4287.

What happened?
not exist

@ikatyang
Copy link
Contributor Author

ikatyang commented Jun 7, 2018

I guess we can simply add a parenthesized: boolean prop for expressions so that the AST structure won't be affected.

@ikatyang
Copy link
Contributor Author

ikatyang commented Jun 7, 2018

Just found another way to fix the problem in Prettier (prettier/prettier#4648).

@ikatyang ikatyang closed this as completed Jun 7, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

1 participant