[ts]No syntax error is thrown for invalid type annotation #12180
Labels
area: typescript
i: bug
i: regression
outdated
A closed issue/PR that is archived due to age. Recommended to make a new issue
pkg: parser
Bug Report
Current behavior
Successful parsing:
AST
Input Code
Expected behavior
Throw syntax error
Did not expect a type annotation here.
.Babel Configuration (babel.config.js, .babelrc, package.json#babel, cli command, .eslintrc)
Environment
@babel/parser
:7.12.0
Possible Solution
Additional context
Found from working on prettier/prettier#9408
This is a 7.12.0 regression
The text was updated successfully, but these errors were encountered: