Chromium Code Reviews| Index: src/ast.cc |
| diff --git a/src/ast.cc b/src/ast.cc |
| index fbefbd46f960ce347d56b8129a0e83de5b8c3843..73d7b96a73e3f6749dab79d048bbdd8b5f6cf8a9 100644 |
| --- a/src/ast.cc |
| +++ b/src/ast.cc |
| @@ -234,9 +234,11 @@ LanguageMode FunctionLiteral::language_mode() const { |
| } |
| -bool FunctionLiteral::uses_super_property() const { |
| - DCHECK_NOT_NULL(scope()); |
| - return scope()->uses_super_property(); |
| +bool FunctionLiteral::NeedsHomeObject(Expression* expr) { |
| + if (expr == nullptr || !expr->IsFunctionLiteral()) return false; |
| + DCHECK_NOT_NULL(expr->AsFunctionLiteral()); |
|
adamk
2015/06/04 20:02:33
This DCHECK seems a little over-anxious, the above
arv (Not doing code reviews)
2015/06/04 20:17:45
Done.
|
| + DCHECK_NOT_NULL(expr->AsFunctionLiteral()->scope()); |
| + return expr->AsFunctionLiteral()->scope()->NeedsHomeObject(); |
| } |