Peeyush Kushwaha 2225892348 Use first binding for multiple var declarations (#5745)
* Use first binding for multiple var declarations
Since var declarations after initial binding have no effect, use the
first declaration. Fixes #2378

* Include hoisted function bindings

* Missing newline in expected.js

* Simplify constantViolations in new Binding on existing

* clarify comment language
2017-07-24 14:43:17 -04:00

10 lines
137 B
JavaScript

module.exports = function() {
return {
visitor: {
Function(path) {
path.scope.rename("a", "z");
}
}
};
}