37 std::stack<ASTNode *> parent;
38 std::map<ASTNode *, std::string> vertexMap;
40 void connect_node_to_parent(
ASTNode *element);
41 void declare_node(
ASTNode *element, std::string label =
"");
42 void pushn(
ASTNode *element,
int n);
43 void process_node(
ASTNode *element);
Abstract base class for all AST nodes.
Definition: ASTNode.h:34
Constructs a dot graph that can be used to visualize the AST.
Definition: ASTVisualizer.h:24
ASTVisualizer(std::ostream &os)
Definition: ASTVisualizer.h:27
void buildGraph(SyntaxTree &tree)
Construct a dot syntax compliant graph of the AST.
Definition: ASTVisualizer.cpp:7
ASTVisualizer()
Definition: ASTVisualizer.h:26
A convenient interface to the AST nodes.
Definition: SyntaxTree.h:16