-
-
Notifications
You must be signed in to change notification settings - Fork 5.8k
Closed
Labels
outdatedA closed issue/PR that is archived due to age. Recommended to make a new issueA closed issue/PR that is archived due to age. Recommended to make a new issue
Description
💻
- Would you like to work on a fix?
How are you using Babel?
Other (Next.js, Gatsby, vue-cli, ...)
Input code
switch ( x ) { default : let x { ; } ; }Configuration file name
No response
Configuration
No response
Current and expected behavior
In the input code, ReferenceError is expected but the transpiled code terminates without any error.
$ node input.js
output.js:1: ReferenceError: x is not defined
switch ( x ) { default : let x ; }
^
ReferenceError: x is not defined
at output.js:1:10$ node output.js # no errorEnvironment
Reproductions on Babel's own REPL
Possible solution
It might be possible to solve this issue by changing var x into var _x.
Additional context
No response
Metadata
Metadata
Assignees
Labels
outdatedA closed issue/PR that is archived due to age. Recommended to make a new issueA closed issue/PR that is archived due to age. Recommended to make a new issue