Index: src/ast-expression-visitor.cc |
diff --git a/src/ast-expression-visitor.cc b/src/ast-expression-visitor.cc |
index 32cf2c75277fc4b3292b08449f2383e3ca4e26b7..d534d1f0f036c1210175cd7f7b89505c7016b860 100644 |
--- a/src/ast-expression-visitor.cc |
+++ b/src/ast-expression-visitor.cc |
@@ -32,20 +32,14 @@ |
} while (false) |
-AstExpressionVisitor::AstExpressionVisitor(Isolate* isolate, Expression* root) |
+AstExpressionVisitor::AstExpressionVisitor(Isolate* isolate, |
+ FunctionLiteral* root) |
: root_(root), depth_(0) { |
InitializeAstVisitor(isolate); |
} |
-AstExpressionVisitor::AstExpressionVisitor(uintptr_t stack_limit, |
- Expression* root) |
- : root_(root), depth_(0) { |
- InitializeAstVisitor(stack_limit); |
-} |
- |
- |
-void AstExpressionVisitor::Run() { RECURSE(Visit(root_)); } |
+void AstExpressionVisitor::Run() { RECURSE(VisitFunctionLiteral(root_)); } |
void AstExpressionVisitor::VisitVariableDeclaration(VariableDeclaration* decl) { |
@@ -229,9 +223,6 @@ |
ZoneList<ObjectLiteralProperty*>* props = expr->properties(); |
for (int i = 0; i < props->length(); ++i) { |
ObjectLiteralProperty* prop = props->at(i); |
- if (!prop->key()->IsLiteral()) { |
- RECURSE_EXPRESSION(Visit(prop->key())); |
- } |
RECURSE_EXPRESSION(Visit(prop->value())); |
} |
} |
@@ -345,27 +336,10 @@ |
} |
-void AstExpressionVisitor::VisitClassLiteral(ClassLiteral* expr) { |
- VisitExpression(expr); |
- if (expr->extends() != nullptr) { |
- RECURSE_EXPRESSION(Visit(expr->extends())); |
- } |
- RECURSE_EXPRESSION(Visit(expr->constructor())); |
- ZoneList<ObjectLiteralProperty*>* props = expr->properties(); |
- for (int i = 0; i < props->length(); ++i) { |
- ObjectLiteralProperty* prop = props->at(i); |
- if (!prop->key()->IsLiteral()) { |
- RECURSE_EXPRESSION(Visit(prop->key())); |
- } |
- RECURSE_EXPRESSION(Visit(prop->value())); |
- } |
-} |
- |
- |
-void AstExpressionVisitor::VisitSpread(Spread* expr) { |
- VisitExpression(expr); |
- RECURSE_EXPRESSION(Visit(expr->expression())); |
-} |
+void AstExpressionVisitor::VisitClassLiteral(ClassLiteral* expr) {} |
+ |
+ |
+void AstExpressionVisitor::VisitSpread(Spread* expr) {} |
void AstExpressionVisitor::VisitEmptyParentheses(EmptyParentheses* expr) {} |