Index: src/parsing/parser.cc |
diff --git a/src/parsing/parser.cc b/src/parsing/parser.cc |
index 603b6c8a33cc78ddbd753511bf0661fe29536845..4bb4038304f0c27be2990dac692e63f552b19e03 100644 |
--- a/src/parsing/parser.cc |
+++ b/src/parsing/parser.cc |
@@ -947,9 +947,9 @@ FunctionLiteral* Parser::DoParseProgram(ParseInfo* info) { |
Scope* scope = NewScriptScope(); |
info->set_script_scope(scope); |
if (!info->context().is_null() && !info->context()->IsNativeContext()) { |
- scope = Scope::DeserializeScopeChain(info->isolate(), zone(), |
- *info->context(), scope, |
- ast_value_factory()); |
+ scope = Scope::DeserializeScopeChain( |
+ info->isolate(), zone(), *info->context(), scope, ast_value_factory(), |
+ Scope::DeserializationMode::kKeepScopeInfo); |
// The Scope is backed up by ScopeInfo (which is in the V8 heap); this |
// means the Parser cannot operate independent of the V8 heap. Tell the |
// string table to internalize strings and values right after they're |
@@ -1116,8 +1116,9 @@ FunctionLiteral* Parser::ParseLazy(Isolate* isolate, ParseInfo* info, |
// Ok to use Isolate here, since lazy function parsing is only done in the |
// main thread. |
DCHECK(parsing_on_main_thread_); |
- scope = Scope::DeserializeScopeChain(isolate, zone(), *info->context(), |
- scope, ast_value_factory()); |
+ scope = Scope::DeserializeScopeChain( |
+ isolate, zone(), *info->context(), scope, ast_value_factory(), |
+ Scope::DeserializationMode::kKeepScopeInfo); |
} |
original_scope_ = scope; |
FunctionState function_state(&function_state_, &scope_state_, scope, |