C-Breeze
C Compiler Infrastructure

[ Project home page]
Main Page   Modules   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

print_walker Class Reference
[phases defined in c-breeze (some of which are available from the command line).]

prints each node to an out stream. More...

#include <print_walker.h>

Inheritance diagram for print_walker:

Walker List of all members.

"at_" methods

These methods define the functions that should be performed when different classes of Nodes are encountered in the AST. The most specific "at_" method that matches a given Node's class will be called.

virtual void at_node (Node *the_node, Order ord)
virtual void at_def (defNode *the_def, Order ord)
virtual void at_subdecl (subdeclNode *the_subdecl, Order ord)
virtual void at_type (typeNode *the_type, Order ord)
virtual void at_struct (structNode *the_struct, Order ord)
virtual void at_union (unionNode *the_union, Order ord)
virtual void at_enum (enumNode *the_enum, Order ord)
virtual void at_expr (exprNode *the_expr, Order ord)
virtual void at_index (indexNode *the_index, Order ord)
virtual void at_stmt (stmtNode *the_stmt, Order ord)
virtual void at_target (targetNode *the_target, Order ord)
virtual void at_selection (selectionNode *the_selection, Order ord)
virtual void at_loop (loopNode *the_loop, Order ord)
virtual void at_jump (jumpNode *the_jump, Order ord)

Public Types

enum  Order { Preorder, Postorder, Both }
 The order in which AST Nodes should be visited. More...

enum  Depth { Subtree, NodeOnly }
 Which Nodes in the AST tree should be visited. More...


Public Member Functions

 print_walker (ostream &out, numbering_map *num)
virtual void at_unit (unitNode *the_unit, Order ord)
virtual void at_decl (declNode *the_decl, Order ord)
virtual void at_proc (procNode *the_proc, Order ord)
virtual void at_prim (primNode *the_prim, Order ord)
virtual void at_tdef (tdefNode *the_tdef, Order ord)
virtual void at_ptr (ptrNode *the_ptr, Order ord)
virtual void at_array (arrayNode *the_array, Order ord)
virtual void at_func (funcNode *the_func, Order ord)
virtual void at_sue (sueNode *the_sue, Order ord)
virtual void at_suespec (suespecNode *the_suespec, Order ord)
virtual void at_const (constNode *the_const, Order ord)
virtual void at_id (idNode *the_id, Order ord)
virtual void at_binary (binaryNode *the_binary, Order ord)
virtual void at_unary (unaryNode *the_unary, Order ord)
virtual void at_cast (castNode *the_cast, Order ord)
virtual void at_comma (commaNode *the_comma, Order ord)
virtual void at_ternary (ternaryNode *the_ternary, Order ord)
virtual void at_call (callNode *the_call, Order ord)
virtual void at_initializer (initializerNode *the_initializer, Order ord)
virtual void at_block (blockNode *the_block, Order ord)
virtual void at_basicblock (basicblockNode *the_bb, Order ord)
virtual void at_exprstmt (exprstmtNode *the_exprstmt, Order ord)
virtual void at_label (labelNode *the_label, Order ord)
virtual void at_case (caseNode *the_case, Order ord)
virtual void at_if (ifNode *the_if, Order ord)
virtual void at_switch (switchNode *the_switch, Order ord)
virtual void at_while (whileNode *the_while, Order ord)
virtual void at_do (doNode *the_do, Order ord)
virtual void at_for (forNode *the_for, Order ord)
virtual void at_goto (gotoNode *the_goto, Order ord)
virtual void at_continue (continueNode *the_continue, Order ord)
virtual void at_break (breakNode *the_break, Order ord)
virtual void at_return (returnNode *the_return, Order ord)
virtual void at_attrib (attribNode *the_attrib, Order ord)
virtual void at_operand (operandNode *the_oper, Order ord)
virtual void at_conditiongoto (conditiongotoNode *the_condgoto, Order ord)
virtual void at_threeAddr (threeAddrNode *the_3addr, Order ord)
virtual void at_text (textNode *the_text, Order ord)

Static Public Member Functions

void print (Node *n, ostream &out)
 To display the AST, call this static function:.


Private Member Functions

void indent (Node *n) const
void in ()
void out ()

Private Attributes

ostream & _out
int _indent
numbering_map_num

Detailed Description

prints each node to an out stream.

Definition at line 45 of file print_walker.h.


Member Enumeration Documentation

enum Walker::Depth [inherited]
 

Which Nodes in the AST tree should be visited.

Enumeration values:
Subtree  The entire AST should be traversed.
NodeOnly  Only the root Node should be visited.

Definition at line 155 of file walker.h.

enum Walker::Order [inherited]
 

The order in which AST Nodes should be visited.

Enumeration values:
Preorder  Nodes should be visited before their children.
Postorder  Nodes should be visited after their children.
Both  Nodes should be visited both before and after their children.

Definition at line 147 of file walker.h.

Referenced by whileNode::walk(), unitNode::walk(), unionNode::walk(), unaryNode::walk(), threeAddrNode::walk(), textNode::walk(), ternaryNode::walk(), tdefNode::walk(), switchNode::walk(), suespecNode::walk(), subdeclNode::walk(), structNode::walk(), returnNode::walk(), ptrNode::walk(), procNode::walk(), primNode::walk(), operandNode::walk(), metastmtNode::walk(), metaexprNode::walk(), labelNode::walk(), initializerNode::walk(), ifNode::walk(), idNode::walk(), gotoNode::walk(), funcNode::walk(), forNode::walk(), exprstmtNode::walk(), enumNode::walk(), doNode::walk(), declNode::walk(), continueNode::walk(), constNode::walk(), conditiongotoNode::walk(), commaNode::walk(), castNode::walk(), caseNode::walk(), callNode::walk(), breakNode::walk(), blockNode::walk(), binaryNode::walk(), basicblockNode::walk(), attribNode::walk(), and arrayNode::walk().


Constructor & Destructor Documentation

print_walker::print_walker ostream &    out,
numbering_map   num
 

Definition at line 60 of file print_walker.cc.


Member Function Documentation

void print_walker::at_array arrayNode   the_array,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 203 of file print_walker.cc.

References _out, arrayNode::dim(), in(), indent(), out(), Walker::Postorder, Walker::Preorder, arrayNode::size(), and typeNode::type_qualifiers_name().

void print_walker::at_attrib attribNode   the_attrib,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 777 of file print_walker.cc.

References _out, in(), indent(), attribNode::name(), out(), Walker::Postorder, and Walker::Preorder.

void print_walker::at_basicblock basicblockNode   the_bb,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 484 of file print_walker.cc.

References _out, blockNode::decls(), in(), indent(), out(), Walker::Postorder, Walker::Preorder, and blockNode::stmts().

void print_walker::at_binary binaryNode   the_binary,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 325 of file print_walker.cc.

References _out, in(), indent(), binaryNode::left(), binaryNode::op(), out(), Walker::Postorder, Walker::Preorder, Operator::print(), and binaryNode::right().

void print_walker::at_block blockNode   the_block,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 463 of file print_walker.cc.

References _out, blockNode::decls(), in(), indent(), out(), Walker::Postorder, Walker::Preorder, and blockNode::stmts().

void print_walker::at_break breakNode   the_break,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 741 of file print_walker.cc.

References _out, breakNode::container(), in(), indent(), out(), Walker::Postorder, and Walker::Preorder.

void print_walker::at_call callNode   the_call,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 422 of file print_walker.cc.

References _out, callNode::args(), in(), indent(), callNode::name(), out(), Walker::Postorder, Walker::Preorder, and callNode::proc().

void print_walker::at_case caseNode   the_case,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 558 of file print_walker.cc.

References _out, caseNode::container(), caseNode::expr(), in(), indent(), out(), Walker::Postorder, Walker::Preorder, and targetNode::stmt().

void print_walker::at_cast castNode   the_cast,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 364 of file print_walker.cc.

References _out, castNode::expr(), in(), indent(), castNode::is_implicit(), out(), Walker::Postorder, and Walker::Preorder.

void print_walker::at_comma commaNode   the_comma,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 385 of file print_walker.cc.

References _out, in(), indent(), out(), Walker::Postorder, and Walker::Preorder.

void print_walker::at_conditiongoto conditiongotoNode   the_condgoto,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 808 of file print_walker.cc.

References _out, in(), indent(), gotoNode::label(), gotoNode::name(), conditiongotoNode::op(), out(), Walker::Postorder, and Walker::Preorder.

void print_walker::at_const constNode   the_const,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 296 of file print_walker.cc.

References _out, in(), indent(), out(), Walker::Postorder, Walker::Preorder, and constNode::text().

void print_walker::at_continue continueNode   the_continue,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 725 of file print_walker.cc.

References _out, continueNode::container(), in(), indent(), out(), Walker::Postorder, and Walker::Preorder.

void print_walker::at_decl declNode   the_decl,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 96 of file print_walker.cc.

References _out, declNode::decl_location(), declNode::decl_location_name(), id_list, id_list_p, in(), indent(), declNode::name(), out(), Walker::Postorder, Walker::Preorder, declNode::ref_list(), declNode::storage_class(), and declNode::storage_class_name().

virtual void Walker::at_def defNode   the_def,
Order    ord
[inline, virtual, inherited]
 

Definition at line 230 of file walker.h.

References Walker::at_node().

Referenced by Walker::at_decl(), and Walker::at_proc().

void print_walker::at_do doNode   the_do,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 660 of file print_walker.cc.

References _out, loopNode::body(), loopNode::cond(), in(), indent(), out(), Walker::Postorder, and Walker::Preorder.

virtual void Walker::at_enum enumNode   the_enum,
Order    ord
[inline, virtual, inherited]
 

Reimplemented in enum_value_walker.

Definition at line 269 of file walker.h.

References Walker::at_sue().

Referenced by enumNode::walk().

virtual void Walker::at_expr exprNode   the_expr,
Order    ord
[inline, virtual, inherited]
 

Reimplemented in NodeLocator, and remove_stale_type_walker.

Definition at line 275 of file walker.h.

References Walker::at_node().

Referenced by Walker::at_binary(), Walker::at_call(), Walker::at_cast(), Walker::at_comma(), Walker::at_index(), Walker::at_initializer(), Walker::at_operand(), Walker::at_ternary(), Walker::at_unary(), and metaexprNode::walk().

void print_walker::at_exprstmt exprstmtNode   the_exprstmt,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 505 of file print_walker.cc.

References _out, exprstmtNode::expr(), in(), indent(), out(), Walker::Postorder, and Walker::Preorder.

void print_walker::at_for forNode   the_for,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 681 of file print_walker.cc.

References _out, loopNode::body(), loopNode::cond(), in(), indent(), forNode::init(), forNode::next(), out(), Walker::Postorder, and Walker::Preorder.

void print_walker::at_func funcNode   the_func,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 221 of file print_walker.cc.

References _out, in(), indent(), out(), Walker::Postorder, Walker::Preorder, and typeNode::type_qualifiers_name().

void print_walker::at_goto gotoNode   the_goto,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 708 of file print_walker.cc.

References _out, in(), indent(), gotoNode::label(), gotoNode::name(), out(), Walker::Postorder, and Walker::Preorder.

void print_walker::at_id idNode   the_id,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 309 of file print_walker.cc.

References _out, idNode::decl(), in(), indent(), idNode::name(), out(), Walker::Postorder, and Walker::Preorder.

void print_walker::at_if ifNode   the_if,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 582 of file print_walker.cc.

References _out, selectionNode::expr(), ifNode::false_br(), in(), indent(), out(), Walker::Postorder, Walker::Preorder, and ifNode::true_br().

virtual void Walker::at_index indexNode   the_index,
Order    ord
[inline, virtual, inherited]
 

Definition at line 278 of file walker.h.

References Walker::at_expr().

Referenced by Walker::at_const(), and Walker::at_id().

void print_walker::at_initializer initializerNode   the_initializer,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 445 of file print_walker.cc.

References _out, initializerNode::exprs(), in(), indent(), out(), Walker::Postorder, and Walker::Preorder.

virtual void Walker::at_jump jumpNode   the_jump,
Order    ord
[inline, virtual, inherited]
 

Definition at line 350 of file walker.h.

References Walker::at_stmt().

Referenced by Walker::at_break(), Walker::at_continue(), Walker::at_goto(), and Walker::at_return().

void print_walker::at_label labelNode   the_label,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 523 of file print_walker.cc.

References _out, goto_list, goto_list_p, in(), indent(), labelNode::name(), out(), Walker::Postorder, Walker::Preorder, labelNode::references(), and targetNode::stmt().

virtual void Walker::at_loop loopNode   the_loop,
Order    ord
[inline, virtual, inherited]
 

Reimplemented in semcheck_walker, set_container_walker, TreeChecker, and init_flowproblem_walker.

Definition at line 338 of file walker.h.

References Walker::at_stmt().

Referenced by Walker::at_do(), Walker::at_for(), and Walker::at_while().

virtual void Walker::at_node Node   the_node,
Order    ord
[inline, virtual, inherited]
 

Reimplemented in gcWalker, goto_label_walker, set_container_walker, sue_complete_walker, TreeChecker, and df_number_walker.

Definition at line 223 of file walker.h.

Referenced by Walker::at_def(), Walker::at_expr(), Walker::at_stmt(), Walker::at_text(), Walker::at_type(), and Walker::at_unit().

void print_walker::at_operand operandNode   the_oper,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 790 of file print_walker.cc.

References _out, operandNode::addr(), in(), indent(), operandNode::index(), out(), Walker::Postorder, Walker::Preorder, and operandNode::star().

void print_walker::at_prim primNode   the_prim,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 150 of file print_walker.cc.

References _out, primNode::basic(), in(), indent(), out(), Walker::Postorder, Walker::Preorder, basic_type::to_string(), and typeNode::type_qualifiers_name().

void print_walker::at_proc procNode   the_proc,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 129 of file print_walker.cc.

References _out, procNode::body(), procNode::decl(), in(), indent(), out(), Walker::Postorder, and Walker::Preorder.

void print_walker::at_ptr ptrNode   the_ptr,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 190 of file print_walker.cc.

References _out, in(), indent(), out(), Walker::Postorder, Walker::Preorder, and typeNode::type_qualifiers_name().

void print_walker::at_return returnNode   the_return,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 757 of file print_walker.cc.

References _out, returnNode::expr(), in(), indent(), out(), Walker::Postorder, Walker::Preorder, and returnNode::proc().

virtual void Walker::at_selection selectionNode   the_selection,
Order    ord
[inline, virtual, inherited]
 

Reimplemented in semcheck_walker.

Definition at line 329 of file walker.h.

References Walker::at_stmt().

Referenced by Walker::at_if(), and Walker::at_switch().

virtual void Walker::at_stmt stmtNode   the_stmt,
Order    ord
[inline, virtual, inherited]
 

Reimplemented in NodeLocator, W, init_flowproblem_walker, and LivenessWalker.

Definition at line 308 of file walker.h.

References Walker::at_node().

Referenced by Walker::at_attrib(), Walker::at_block(), Walker::at_exprstmt(), Walker::at_jump(), Walker::at_loop(), Walker::at_selection(), Walker::at_target(), Walker::at_threeAddr(), and metastmtNode::walk().

virtual void Walker::at_struct structNode   the_struct,
Order    ord
[inline, virtual, inherited]
 

Definition at line 263 of file walker.h.

References Walker::at_sue().

Referenced by structNode::walk().

virtual void Walker::at_subdecl subdeclNode   the_subdecl,
Order    ord
[inline, virtual, inherited]
 

Definition at line 236 of file walker.h.

References Walker::at_decl().

Referenced by subdeclNode::walk().

void print_walker::at_sue sueNode   the_sue,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 234 of file print_walker.cc.

References _out, Enum, in(), indent(), suespecNode::name(), out(), Walker::Postorder, Walker::Preorder, sueNode::spec(), Struct, Node::typ(), and Union.

void print_walker::at_suespec suespecNode   the_suespec,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 269 of file print_walker.cc.

References _out, suespecNode::align(), suespecNode::complete(), in(), indent(), suespecNode::name(), out(), Walker::Postorder, Walker::Preorder, suespecNode::size(), typeNode::type_qualifiers_name(), and suespecNode::visited().

void print_walker::at_switch switchNode   the_switch,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 606 of file print_walker.cc.

References _out, switchNode::cases(), selectionNode::expr(), in(), indent(), out(), Walker::Postorder, Walker::Preorder, selectionNode::stmt(), target_list, and target_list_p.

virtual void Walker::at_target targetNode   the_target,
Order    ord
[inline, virtual, inherited]
 

Reimplemented in init_flowproblem_walker.

Definition at line 320 of file walker.h.

References Walker::at_stmt().

Referenced by Walker::at_case(), and Walker::at_label().

void print_walker::at_tdef tdefNode   the_tdef,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 167 of file print_walker.cc.

References _out, tdefNode::def(), in(), indent(), tdefNode::name(), out(), Walker::Postorder, Walker::Preorder, and typeNode::type_qualifiers_name().

void print_walker::at_ternary ternaryNode   the_ternary,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 398 of file print_walker.cc.

References _out, ternaryNode::cond(), ternaryNode::false_br(), in(), indent(), out(), Walker::Postorder, Walker::Preorder, and ternaryNode::true_br().

void print_walker::at_text textNode   the_text,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 841 of file print_walker.cc.

References _out, in(), indent(), out(), Walker::Postorder, Walker::Preorder, and textNode::text().

void print_walker::at_threeAddr threeAddrNode   the_3addr,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 825 of file print_walker.cc.

References _out, in(), indent(), threeAddrNode::op(), out(), Walker::Postorder, and Walker::Preorder.

virtual void Walker::at_type typeNode   the_type,
Order    ord
[inline, virtual, inherited]
 

Reimplemented in W, and TreeChecker.

Definition at line 242 of file walker.h.

References Walker::at_node().

Referenced by Walker::at_array(), Walker::at_func(), Walker::at_prim(), Walker::at_ptr(), Walker::at_sue(), Walker::at_suespec(), and Walker::at_tdef().

void print_walker::at_unary unaryNode   the_unary,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 346 of file print_walker.cc.

References _out, unaryNode::expr(), in(), indent(), unaryNode::op(), out(), Walker::Postorder, Walker::Preorder, and Operator::print().

virtual void Walker::at_union unionNode   the_union,
Order    ord
[inline, virtual, inherited]
 

Definition at line 266 of file walker.h.

References Walker::at_sue().

Referenced by unionNode::walk().

void print_walker::at_unit unitNode   the_unit,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 83 of file print_walker.cc.

References _out, in(), indent(), out(), Walker::Postorder, and Walker::Preorder.

void print_walker::at_while whileNode   the_while,
Order    ord
[virtual]
 

Reimplemented from Walker.

Definition at line 639 of file print_walker.cc.

References _out, loopNode::body(), loopNode::cond(), in(), indent(), out(), Walker::Postorder, and Walker::Preorder.

Depth Walker::depth   const [inline, inherited]
 

Return which Nodes of an AST should be visited.

A value of SubTree specifies that the entire AST should be traversed. A value of NodeOnly specifies that only the root Node in the AST should be visited.

Definition at line 211 of file walker.h.

Referenced by whileNode::walk(), unitNode::walk(), unionNode::walk(), unaryNode::walk(), threeAddrNode::walk(), ternaryNode::walk(), switchNode::walk(), suespecNode::walk(), subdeclNode::walk(), structNode::walk(), returnNode::walk(), ptrNode::walk(), procNode::walk(), operandNode::walk(), metastmtNode::walk(), metaexprNode::walk(), labelNode::walk(), initializerNode::walk(), ifNode::walk(), idNode::walk(), funcNode::walk(), forNode::walk(), exprstmtNode::walk(), enumNode::walk(), doNode::walk(), declNode::walk(), constNode::walk(), conditiongotoNode::walk(), commaNode::walk(), castNode::walk(), caseNode::walk(), callNode::walk(), blockNode::walk(), binaryNode::walk(), basicblockNode::walk(), attribNode::walk(), arrayNode::walk(), and Walker::Walker().

void print_walker::in   [inline, private]
 

Definition at line 61 of file print_walker.h.

Referenced by at_array(), at_attrib(), at_basicblock(), at_binary(), at_block(), at_break(), at_call(), at_case(), at_cast(), at_comma(), at_conditiongoto(), at_const(), at_continue(), at_decl(), at_do(), at_exprstmt(), at_for(), at_func(), at_goto(), at_id(), at_if(), at_initializer(), at_label(), at_operand(), at_prim(), at_proc(), at_ptr(), at_return(), at_sue(), at_suespec(), at_switch(), at_tdef(), at_ternary(), at_text(), at_threeAddr(), at_unary(), at_unit(), and at_while().

void print_walker::indent Node   n const [private]
 

Definition at line 67 of file print_walker.cc.

References _out.

Referenced by at_array(), at_attrib(), at_basicblock(), at_binary(), at_block(), at_break(), at_call(), at_case(), at_cast(), at_comma(), at_conditiongoto(), at_const(), at_continue(), at_decl(), at_do(), at_exprstmt(), at_for(), at_func(), at_goto(), at_id(), at_if(), at_initializer(), at_label(), at_operand(), at_prim(), at_proc(), at_ptr(), at_return(), at_sue(), at_suespec(), at_switch(), at_tdef(), at_ternary(), at_text(), at_threeAddr(), at_unary(), at_unit(), and at_while().

Order Walker::order   const [inline, inherited]
 

Return the order in which Nodes of an AST should be visited.

Nodes can be visited before their children (Preorder), after their children (Postorder), or both (Both).

Definition at line 203 of file walker.h.

Referenced by df_number_walker::at_node(), whileNode::walk(), unitNode::walk(), unionNode::walk(), unaryNode::walk(), threeAddrNode::walk(), textNode::walk(), ternaryNode::walk(), tdefNode::walk(), switchNode::walk(), suespecNode::walk(), subdeclNode::walk(), structNode::walk(), returnNode::walk(), ptrNode::walk(), procNode::walk(), primNode::walk(), operandNode::walk(), metastmtNode::walk(), metaexprNode::walk(), labelNode::walk(), initializerNode::walk(), ifNode::walk(), idNode::walk(), gotoNode::walk(), funcNode::walk(), forNode::walk(), exprstmtNode::walk(), enumNode::walk(), doNode::walk(), declNode::walk(), continueNode::walk(), constNode::walk(), conditiongotoNode::walk(), commaNode::walk(), castNode::walk(), caseNode::walk(), callNode::walk(), breakNode::walk(), blockNode::walk(), binaryNode::walk(), basicblockNode::walk(), attribNode::walk(), and arrayNode::walk().

void print_walker::out   [inline, private]
 

Definition at line 62 of file print_walker.h.

Referenced by at_array(), at_attrib(), at_basicblock(), at_binary(), at_block(), at_break(), at_call(), at_case(), at_cast(), at_comma(), at_conditiongoto(), at_const(), at_continue(), at_decl(), at_do(), at_exprstmt(), at_for(), at_func(), at_goto(), at_id(), at_if(), at_initializer(), at_label(), at_operand(), at_prim(), at_proc(), at_ptr(), at_return(), at_sue(), at_suespec(), at_switch(), at_tdef(), at_ternary(), at_text(), at_threeAddr(), at_unary(), at_unit(), and at_while().

void print_walker::print Node   n,
ostream &    out
[static]
 

To display the AST, call this static function:.

Definition at line 46 of file print_walker.cc.

References df_number_walker::number(), numbering_map, and Node::walk().

Referenced by TreeChecker::checkTree(), and print_ast_phase::run().


Member Data Documentation

int print_walker::_indent [private]
 

Definition at line 56 of file print_walker.h.

numbering_map* print_walker::_num [private]
 

Definition at line 57 of file print_walker.h.

ostream& print_walker::_out [private]
 

Definition at line 55 of file print_walker.h.

Referenced by at_array(), at_attrib(), at_basicblock(), at_binary(), at_block(), at_break(), at_call(), at_case(), at_cast(), at_comma(), at_conditiongoto(), at_const(), at_continue(), at_decl(), at_do(), at_exprstmt(), at_for(), at_func(), at_goto(), at_id(), at_if(), at_initializer(), at_label(), at_operand(), at_prim(), at_proc(), at_ptr(), at_return(), at_sue(), at_suespec(), at_switch(), at_tdef(), at_ternary(), at_text(), at_threeAddr(), at_unary(), at_unit(), at_while(), and indent().


The documentation for this class was generated from the following files:

Generated on August 27, 2003
Back to the C-Breeze home page