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

Unified Diff: src/ast/ast.h

Issue 1587543003: Adding AstNode::PrettyPrint and AstNode::PrintAst (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: don't generate methods in release Created 4 years, 11 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 | « no previous file | src/ast/ast.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/ast/ast.h
diff --git a/src/ast/ast.h b/src/ast/ast.h
index 7f00955a644fcaeeeca1be192c67a5afa7ec0b70..a81f16742481332d61bac3e42b6fd67577977cdf 100644
--- a/src/ast/ast.h
+++ b/src/ast/ast.h
@@ -196,6 +196,13 @@ class AstNode: public ZoneObject {
virtual NodeType node_type() const = 0;
int position() const { return position_; }
+#ifdef DEBUG
+ void PrettyPrint(Isolate* isolate);
+ void PrettyPrint();
+ void PrintAst(Isolate* isolate);
+ void PrintAst();
+#endif // DEBUG
+
// Type testing & conversion functions overridden by concrete subclasses.
#define DECLARE_NODE_FUNCTIONS(type) \
bool Is##type() const { return node_type() == AstNode::k##type; } \
« no previous file with comments | « no previous file | src/ast/ast.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698