diff --git a/src/ast/scopes.cc b/src/ast/scopes.cc index a2d9779fc337..1ebe09bc5b64 100644 --- a/src/ast/scopes.cc +++ b/src/ast/scopes.cc @@ -1244,10 +1244,6 @@ Variable* DeclarationScope::DeclareDynamicGlobal(const AstRawString* name, // TODO(neis): Mark variable as maybe-assigned? } -bool Scope::RemoveUnresolved(VariableProxy* var) { - return unresolved_list_.Remove(var); -} - void Scope::DeleteUnresolved(VariableProxy* var) { DCHECK(unresolved_list_.Contains(var)); var->mark_removed_from_unresolved(); diff --git a/src/ast/scopes.h b/src/ast/scopes.h index 63d8f4d2cd14..6b9e1f5607c2 100644 --- a/src/ast/scopes.h +++ b/src/ast/scopes.h @@ -227,9 +227,6 @@ class V8_EXPORT_PRIVATE Scope : public NON_EXPORTED_BASE(ZoneObject) { VariableProxy* NewUnresolved(AstNodeFactory* factory, const AstRawString* name, int start_pos, VariableKind kind = NORMAL_VARIABLE) { - // Note that we must not share the unresolved variables with - // the same name because they may be removed selectively via - // RemoveUnresolved(). DCHECK(!already_resolved_); DCHECK_EQ(factory->zone(), zone()); VariableProxy* proxy = factory->NewVariableProxy(name, kind, start_pos); @@ -239,11 +236,6 @@ class V8_EXPORT_PRIVATE Scope : public NON_EXPORTED_BASE(ZoneObject) { void AddUnresolved(VariableProxy* proxy); - // Removes an unresolved variable from the list so it can be readded to - // another list. This is used to reparent parameter initializers that contain - // sloppy eval. - bool RemoveUnresolved(VariableProxy* var); - // Deletes an unresolved variable. The variable proxy cannot be reused for // another list later. During parsing, an unresolved variable may have been // added optimistically, but then only the variable name was used (typically