Index: src/ast/scopes.cc |
diff --git a/src/ast/scopes.cc b/src/ast/scopes.cc |
index 6b6532149f05df1a5be973299ce35234a02c715e..36f5b8bbf3179fe495ff42309f777ee1a70095ff 100644 |
--- a/src/ast/scopes.cc |
+++ b/src/ast/scopes.cc |
@@ -376,17 +376,16 @@ Scope* Scope::DeserializeScopeChain(Isolate* isolate, Zone* zone, |
} |
DCHECK(!scope_info->HasOuterScopeInfo()); |
break; |
- } else if (scope_info->scope_type() == FUNCTION_SCOPE || |
- scope_info->scope_type() == EVAL_SCOPE) { |
- // TODO(neis): For an eval scope, we currently create an ordinary function |
- // context. This is wrong and needs to be fixed. |
- // https://bugs.chromium.org/p/v8/issues/detail?id=5295 |
+ } else if (scope_info->scope_type() == FUNCTION_SCOPE) { |
outer_scope = |
new (zone) DeclarationScope(zone, FUNCTION_SCOPE, handle(scope_info)); |
if (scope_info->IsAsmFunction()) |
outer_scope->AsDeclarationScope()->set_asm_function(); |
if (scope_info->IsAsmModule()) |
outer_scope->AsDeclarationScope()->set_asm_module(); |
+ } else if (scope_info->scope_type() == EVAL_SCOPE) { |
+ outer_scope = |
+ new (zone) DeclarationScope(zone, EVAL_SCOPE, handle(scope_info)); |
} else if (scope_info->scope_type() == BLOCK_SCOPE) { |
if (scope_info->is_declaration_scope()) { |
outer_scope = |