Use the ES6 scope creator in ChromePass.
@@ -110,7 +110,7 @@ public class ChromePass extends AbstractPostOrderCallback implements CompilerPas
@Override
public void process(Node externs, Node root) {
- NodeTraversal.traverse(compiler, root, this);
+ NodeTraversal.traverseEs6(compiler, root, this);
}
@Override
@@ -330,7 +330,7 @@ public class ChromePass extends AbstractPostOrderCallback implements CompilerPas
Map<String, String> exports = objectLitToMap(objectLit);
- NodeTraversal.traverse(
+ NodeTraversal.traverseEs6(
compiler,
functionBlock,
new RenameInternalsToExternalsCallback(namespace, exports, functionBlock));
