-
-
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?
Programmatic API (babel.transform, babel.parse)
Input code
I was able to replicate this issue in babeljs.io with the following code:
function w() {
for (let i = 0; i < y; i++) {
let outer = {}
for (var key in someObj) {
let x = () => outer;
}
}
}Configuration file name
No response
Configuration
Using the transform-block-scoping plugin only.
Current and expected behavior
Expected Babel to be able to parse & transform the code without throwing any exceptions.
Actual behavior is an error:
/repl.js: Property left of ForInStatement expected node to be of a type ["VariableDeclaration","LVal"] but instead got undefined
Environment
I could replicate this issue in babeljs.io
Possible solution
No response
Additional context
No response
Reactions are currently unavailable
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