| Index: src/ast/scopes.cc
|
| diff --git a/src/ast/scopes.cc b/src/ast/scopes.cc
|
| index 22661ec2b0bd91e90efc2fc27a1083417dcba83f..d9f34c894238ce934848e3636e7a361e0b602208 100644
|
| --- a/src/ast/scopes.cc
|
| +++ b/src/ast/scopes.cc
|
| @@ -1153,6 +1153,7 @@ int Scope::ContextChainLengthUntilOutermostSloppyEval() const {
|
| int Scope::MaxNestedContextChainLength() {
|
| int max_context_chain_length = 0;
|
| for (Scope* scope = inner_scope_; scope != nullptr; scope = scope->sibling_) {
|
| + if (scope->is_function_scope()) continue;
|
| max_context_chain_length = std::max(scope->MaxNestedContextChainLength(),
|
| max_context_chain_length);
|
| }
|
|
|