Index: src/ast/ast-traversal-visitor.h |
diff --git a/src/ast/ast-traversal-visitor.h b/src/ast/ast-traversal-visitor.h |
index 38788769073a139d770cb619093ce901f3438e07..d93e02ffe0b2b634fb6ada9cc845f92285dbb24d 100644 |
--- a/src/ast/ast-traversal-visitor.h |
+++ b/src/ast/ast-traversal-visitor.h |
@@ -40,7 +40,7 @@ class AstTraversalVisitor : public AstVisitor<Subclass> { |
bool VisitExpression(Expression* node) { return true; } |
// Iteration left-to-right. |
- void VisitDeclarations(ZoneList<Declaration*>* declarations); |
+ void VisitDeclarations(Declaration::List* declarations); |
void VisitStatements(ZoneList<Statement*>* statements); |
// Individual nodes |
@@ -104,9 +104,8 @@ AstTraversalVisitor<Subclass>::AstTraversalVisitor(uintptr_t stack_limit, |
template <class Subclass> |
void AstTraversalVisitor<Subclass>::VisitDeclarations( |
- ZoneList<Declaration*>* decls) { |
- for (int i = 0; i < decls->length(); ++i) { |
- Declaration* decl = decls->at(i); |
+ Declaration::List* decls) { |
+ for (Declaration* decl : *decls) { |
RECURSE(Visit(decl)); |
} |
} |