Index: src/ast/ast.h |
diff --git a/src/ast/ast.h b/src/ast/ast.h |
index bee0bab47e5640cbcf43c89e3739993d8fdfac73..ee04f00ab9ac80a4ad736cd83200b5066f1c4ea9 100644 |
--- a/src/ast/ast.h |
+++ b/src/ast/ast.h |
@@ -3053,20 +3053,26 @@ class AstVisitor BASE_EMBEDDED { |
class AstTraversalVisitor : public AstVisitor { |
public: |
explicit AstTraversalVisitor(Isolate* isolate); |
+ explicit AstTraversalVisitor(uintptr_t stack_limit); |
virtual ~AstTraversalVisitor() {} |
// Iteration left-to-right. |
void VisitDeclarations(ZoneList<Declaration*>* declarations) override; |
void VisitStatements(ZoneList<Statement*>* statements) override; |
- void VisitExpressions(ZoneList<Expression*>* expressions) override; |
// Individual nodes |
#define DECLARE_VISIT(type) void Visit##type(type* node) override; |
AST_NODE_LIST(DECLARE_VISIT) |
#undef DECLARE_VISIT |
+ protected: |
+ int depth() { return depth_; } |
+ |
private: |
DEFINE_AST_VISITOR_SUBCLASS_MEMBERS(); |
+ |
+ int depth_; |
+ |
DISALLOW_COPY_AND_ASSIGN(AstTraversalVisitor); |
}; |