Index: src/ast/scopes.cc |
diff --git a/src/ast/scopes.cc b/src/ast/scopes.cc |
index 4ce1c0d85f7970f0b1cd5807d0519aac825d88c3..6b3047fb030a277cb900d2e70dcc712decbfef76 100644 |
--- a/src/ast/scopes.cc |
+++ b/src/ast/scopes.cc |
@@ -546,9 +546,9 @@ void DeclarationScope::Analyze(ParseInfo* info, AnalyzeMode mode) { |
// 1) top-level code, |
// 2) a function/eval/module on the top-level |
// 3) a function/eval in a scope that was already resolved. |
- DCHECK(scope->scope_type() == SCRIPT_SCOPE || |
- scope->outer_scope()->scope_type() == SCRIPT_SCOPE || |
- scope->outer_scope()->already_resolved_); |
+ // DCHECK(scope->scope_type() == SCRIPT_SCOPE || |
titzer
2016/11/28 10:40:11
Can you explain why this DCHECK is no longer neede
marja
2016/11/28 11:10:17
I think these commented-out-DCHECKs are stuff that
bradn
2016/11/29 06:30:35
Done.
bradn
2016/11/29 06:30:35
Added back with new case and comment.
|
+ // scope->outer_scope()->scope_type() == SCRIPT_SCOPE || |
+ // scope->outer_scope()->already_resolved_); |
// The outer scope is never lazy. |
scope->set_should_eager_compile(); |
titzer
2016/11/28 10:40:11
Fishy. I don't think we want to set eager compile
bradn
2016/11/29 06:30:35
I think this ends up being moot in the asm case, a
|
@@ -1006,7 +1006,7 @@ VariableProxy* Scope::NewUnresolved(AstNodeFactory* factory, |
// the same name because they may be removed selectively via |
// RemoveUnresolved(). |
DCHECK(!already_resolved_); |
- DCHECK_EQ(factory->zone(), zone()); |
+ // DCHECK_EQ(factory->zone(), zone()); |
titzer
2016/11/28 10:40:11
delete
marja
2016/11/28 11:47:21
No, don't delete :)
bradn
2016/11/29 06:30:35
Keeping with additional clause.
|
VariableProxy* proxy = factory->NewVariableProxy(name, kind, start_position); |
proxy->set_next_unresolved(unresolved_); |
unresolved_ = proxy; |
@@ -1736,7 +1736,7 @@ void Scope::ResolveTo(ParseInfo* info, VariableProxy* proxy, Variable* var) { |
} |
void Scope::ResolveVariablesRecursively(ParseInfo* info) { |
- DCHECK(info->script_scope()->is_script_scope()); |
+ // DCHECK(info->script_scope()->is_script_scope()); |
titzer
2016/11/28 10:40:11
delete
marja
2016/11/28 11:47:21
Ditto, don't delete; but I think this needs to be
bradn
2016/11/29 06:30:35
Kept instead.
bradn
2016/11/29 06:30:35
doing this above.
Actually this one can be kept as
|
// Lazy parsed declaration scopes are already partially analyzed. If there are |
// unresolved references remaining, they just need to be resolved in outer |
// scopes. |