Merge branch 'master' into harmony-v3.0.17

This commit is contained in:
alexlamsl
2017-06-15 19:01:36 +08:00
7 changed files with 90 additions and 8 deletions

View File

@@ -246,11 +246,10 @@ AST_Toplevel.DEFMETHOD("figure_out_scope", function(options){
}
}
var sym = node.scope.find_variable(name);
if (node.scope instanceof AST_Lambda && name == "arguments") {
node.scope.uses_arguments = true;
}
if (!sym) {
sym = self.def_global(node);
} else if (sym.scope instanceof AST_Lambda && name == "arguments") {
sym.scope.uses_arguments = true;
}
node.thedef = sym;
node.reference(options);