Main Page   Modules   Namespace List   Class Hierarchy   Compound List   File List   Compound Members   File Members   Related Pages  

targetNode Class Reference

Jump target. More...

#include <ast.h>

Inheritance diagram for targetNode::

stmtNode Node caseNode labelNode List of all members.

Public Methods

 targetNode (NodeType typ, stmtNode *stmt, const Coord coord)
 Create a new target node. More...

virtual ~targetNode ()
 Destroy a targetNode. More...

Accessors
Methods to get and set fields in the class.

blockNode * stmt () const
blockNode * get_stmt ()
void stmt (blockNode *stmt)
FlowVal * at_entry () const
void at_entry (FlowVal *ae)

Private Attributes

TREE blockNode * _stmt
 the target statement. More...

FlowVal * _at_entry
 dataflow analysis entry value. More...


Detailed Description

Jump target.

This class provides a base class for all statements that serve as targets for jumps. This includes the regular goto labels, as well as the switch cases and default. Note that in C, all labels refer to a statement. Syntactically, the labelled statement in the child of the label. For example, "case 5: x = 10; " results in a labelNode that has an exprstmtNode as it's child.

The NodeType is determined by the subclass (either Label, Case, or Default).


Constructor & Destructor Documentation

targetNode::targetNode (  NodeType    typ,
stmtNode *    stmt,
const Coord    coord
) 
 

Create a new target node.

The new node has the given type and target statement.

Parameters:
typ  the kind of target node (either Label, Case, or Default)
stmt  the target statement

targetNode::~targetNode (    )  [virtual]
 

Destroy a targetNode.

Warning:
Do not use the destructors to delete AST nodes. Instead, rely on the node garbage collector.


Member Function Documentation

void targetNode::at_entry (  FlowVal *    ae )  [inline]
 

FlowVal* targetNode::at_entry (    )  const [inline]
 

blockNode* targetNode::get_stmt (    )  [inline]
 

void targetNode::stmt (  blockNode *    stmt )  [inline]
 

blockNode* targetNode::stmt (    )  const [inline]
 


Member Data Documentation

FlowVal* targetNode::_at_entry [private]
 

dataflow analysis entry value.

This field is used by the dataflow analysis framework to accumulate the flow-value coming in from the various jump statements.

TREE blockNode* targetNode::_stmt [private]
 

the target statement.


The documentation for this class was generated from the following files:
Generated on Thu Jan 10 12:06:34 2002 for C-Breeze by doxygen1.2.13.1 written by Dimitri van Heesch, © 1997-2001