Transpiling loop bodies to functions emits wrong code with aliased variables
Open
bug
- Dominant language
- JavaScript
- Stars
- 874
- Forks
- 62
- PR merge metrics
- No merged PRs in 30d
Description
Example:
```js
let i;
for(let i in { a:1, b:1 }) {
(function(){ return i; })();
}
```
Generates:
```js
var i;
var loop = function ( i ) {
(function(){ return i$1; })();
};
for(var i$1 in { a:1, b:1 }) loop( i );
```
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.