ROSE
0.9.6a
|
Attribute Evaluator for inherited attributes. More...
#include <AstProcessing.h>
Public Member Functions | |
void | traverse (SgNode *node, InheritedAttributeType inheritedValue) |
evaluates attributes on the entire AST More... | |
void | traverseWithinFile (SgNode *node, InheritedAttributeType inheritedValue) |
evaluates attributes only at nodes which represent the same file as where the evaluation was started More... | |
Public Member Functions inherited from SgTreeTraversal< InheritedAttributeType, DummyAttribute > | |
DummyAttribute | traverse (SgNode *basenode, InheritedAttributeType inheritedValue, t_traverseOrder travOrder=preandpostorder) |
DummyAttribute | traverseWithinFile (SgNode *basenode, InheritedAttributeType inheritedValue, t_traverseOrder travOrder=preandpostorder) |
void | traverseInputFiles (SgProject *projectNode, InheritedAttributeType inheritedValue, t_traverseOrder travOrder=preandpostorder) |
virtual | ~SgTreeTraversal () |
SgTreeTraversal () | |
SgTreeTraversal (const SgTreeTraversal &) | |
const SgTreeTraversal & | operator= (const SgTreeTraversal &) |
Protected Member Functions | |
virtual InheritedAttributeType | evaluateInheritedAttribute (SgNode *astNode, InheritedAttributeType inheritedValue)=0 |
pure virtual function which must be implemented to compute the inherited attribute at a node More... | |
virtual void | atTraversalStart () |
Function called at the start of the traversal, before any node is visited; override if necessary, the default implementation is a no-op. More... | |
virtual void | atTraversalEnd () |
virtual void | destroyInheritedValue (SgNode *, InheritedAttributeType) |
Protected Member Functions inherited from SgTreeTraversal< InheritedAttributeType, DummyAttribute > | |
virtual DummyAttribute | evaluateSynthesizedAttribute (SgNode *n, InheritedAttributeType in, SynthesizedAttributesList l)=0 |
virtual void | setNodeSuccessors (SgNode *node, SuccessorsContainer &succContainer) |
void | set_useDefaultIndexBasedTraversal (bool) |
Private Member Functions | |
DummyAttribute | evaluateSynthesizedAttribute (SgNode *astNode, InheritedAttributeType inheritedValue, SynthesizedAttributesList l) |
DummyAttribute | defaultSynthesizedAttribute (InheritedAttributeType inh) |
Friends | |
class | AstCombinedTopDownProcessing< InheritedAttributeType > |
class | DistributedMemoryAnalysisPreTraversal< InheritedAttributeType > |
Additional Inherited Members | |
Protected Types inherited from SgTreeTraversal< InheritedAttributeType, DummyAttribute > | |
typedef AstSuccessorsSelectors::SuccessorsContainer | SuccessorsContainer |
typedef SuccessorsContainer & | SuccessorsContainerRef |
Attribute Evaluator for inherited attributes.
This class allows to compute inherited attributes on the AST. It requires an inherited attribute type as a template parameter and the implementation of the function evaluateInheritedAttribute. This function is invoked in pre-order while the AST is traversed. It can be used for passing context information down the AST.
This class is derived from the SgTreeTraversal class.
Definition at line 237 of file AstProcessing.h.
typedef SgTreeTraversal<InheritedAttributeType, DummyAttribute>::SynthesizedAttributesList AstTopDownProcessing< InheritedAttributeType >::SynthesizedAttributesList |
Definition at line 242 of file AstProcessing.h.
void AstTopDownProcessing< InheritedAttributeType >::traverse | ( | SgNode * | node, |
InheritedAttributeType | inheritedValue | ||
) |
evaluates attributes on the entire AST
Definition at line 536 of file AstProcessing.h.
Referenced by parallelTopDownProcessingThread().
void AstTopDownProcessing< InheritedAttributeType >::traverseWithinFile | ( | SgNode * | node, |
InheritedAttributeType | inheritedValue | ||
) |
evaluates attributes only at nodes which represent the same file as where the evaluation was started
Definition at line 549 of file AstProcessing.h.
|
protectedpure virtual |
pure virtual function which must be implemented to compute the inherited attribute at a node
Implements SgTreeTraversal< InheritedAttributeType, DummyAttribute >.
Implemented in AstSharedMemoryParallelizableTopDownProcessing< InheritedAttributeType >, AstCombinedTopDownProcessing< InheritedAttributeType >, CallgraphTraversal, ClasshierarchyTraversal, and FunctionNamesPreTraversal.
|
protectedvirtual |
Function called at the start of the traversal, before any node is visited; override if necessary, the default implementation is a no-op.
Reimplemented from SgTreeTraversal< InheritedAttributeType, DummyAttribute >.
Reimplemented in AstCombinedTopDownProcessing< InheritedAttributeType >, and AstCombinedTopDownProcessing< I >.
Definition at line 925 of file AstProcessing.h.
|
protectedvirtual |
Reimplemented from SgTreeTraversal< InheritedAttributeType, DummyAttribute >.
Reimplemented in AstSharedMemoryParallelizableTopDownProcessing< InheritedAttributeType >, AstSharedMemoryParallelizableTopDownProcessing< I >, AstCombinedTopDownProcessing< InheritedAttributeType >, and AstCombinedTopDownProcessing< I >.
Definition at line 932 of file AstProcessing.h.
|
protectedvirtual |
Reimplemented in AstCombinedTopDownProcessing< InheritedAttributeType >.
Definition at line 918 of file AstProcessing.h.
|
private |
Definition at line 509 of file AstProcessing.h.
|
privatevirtual |
Reimplemented from SgTreeTraversal< InheritedAttributeType, DummyAttribute >.
Definition at line 525 of file AstProcessing.h.
|
friend |
Definition at line 252 of file AstProcessing.h.
|
friend |
Definition at line 253 of file AstProcessing.h.