Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(92)

Unified Diff: src/compiler/ast-graph-builder.cc

Issue 2142233003: Templatize AstVisitor with its subclass (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Addressed comments Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/compiler/ast-graph-builder.h ('k') | src/compiler/ast-loop-assignment-analyzer.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/ast-graph-builder.cc
diff --git a/src/compiler/ast-graph-builder.cc b/src/compiler/ast-graph-builder.cc
index 16bed66fda226697f1239c2975666e91564e4d1d..01da4bf331a3338c85d94e564cf346edfa7a1ecc 100644
--- a/src/compiler/ast-graph-builder.cc
+++ b/src/compiler/ast-graph-builder.cc
@@ -1112,7 +1112,7 @@ void AstGraphBuilder::VisitForValues(ZoneList<Expression*>* exprs) {
void AstGraphBuilder::VisitForValue(Expression* expr) {
AstValueContext for_value(this);
if (!CheckStackOverflow()) {
- expr->Accept(this);
+ AstVisitor<AstGraphBuilder>::Visit(expr);
} else {
ast_context()->ProduceValue(expr, jsgraph()->UndefinedConstant());
}
@@ -1122,7 +1122,7 @@ void AstGraphBuilder::VisitForValue(Expression* expr) {
void AstGraphBuilder::VisitForEffect(Expression* expr) {
AstEffectContext for_effect(this);
if (!CheckStackOverflow()) {
- expr->Accept(this);
+ AstVisitor<AstGraphBuilder>::Visit(expr);
} else {
ast_context()->ProduceValue(expr, jsgraph()->UndefinedConstant());
}
@@ -1132,7 +1132,7 @@ void AstGraphBuilder::VisitForEffect(Expression* expr) {
void AstGraphBuilder::VisitForTest(Expression* expr) {
AstTestContext for_condition(this, expr->test_id());
if (!CheckStackOverflow()) {
- expr->Accept(this);
+ AstVisitor<AstGraphBuilder>::Visit(expr);
} else {
ast_context()->ProduceValue(expr, jsgraph()->UndefinedConstant());
}
@@ -1142,7 +1142,7 @@ void AstGraphBuilder::VisitForTest(Expression* expr) {
void AstGraphBuilder::Visit(Expression* expr) {
// Reuses enclosing AstContext.
if (!CheckStackOverflow()) {
- expr->Accept(this);
+ AstVisitor<AstGraphBuilder>::Visit(expr);
} else {
ast_context()->ProduceValue(expr, jsgraph()->UndefinedConstant());
}
@@ -2982,7 +2982,7 @@ void AstGraphBuilder::VisitCaseClause(CaseClause* expr) {
void AstGraphBuilder::VisitDeclarations(ZoneList<Declaration*>* declarations) {
DCHECK(globals()->empty());
- AstVisitor::VisitDeclarations(declarations);
+ AstVisitor<AstGraphBuilder>::VisitDeclarations(declarations);
if (globals()->empty()) return;
int array_index = 0;
Handle<TypeFeedbackVector> feedback_vector(
« no previous file with comments | « src/compiler/ast-graph-builder.h ('k') | src/compiler/ast-loop-assignment-analyzer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698