ROSE 0.11.145.147
Public Types | Public Member Functions | List of all members
SgCopyHelp Class Referenceabstract

Description

Supporting class from copy mechanism within ROSE.

This class forms a base class for the SgShallowCopy and SgTreeCopy classes to support the control of copying of subtrees (what IR nodes are copied by a deep or shallow copy).

To tailor a specific type of copy operation derive a class from this abstract class and define the clone_node function as required. context information if required muyst be obtained through local analysis inside the function using the parent or scope information at each IR node.

Note
This is an abstract class.

Definition at line 25 of file sageCopy.h.

#include <sageInterface/sageCopy.h>

Inheritance diagram for SgCopyHelp:
Inheritance graph
[legend]

Public Types

typedef std::map< const SgNode *, SgNode * > copiedNodeMapType
 
typedef copiedNodeMapType::iterator copiedNodeMapTypeIterator
 

Public Member Functions

virtual SgNodecopyAst (const SgNode *n)=0
 
int get_depth ()
 
void incrementDepth ()
 
void decrementDepth ()
 
copiedNodeMapType & get_copiedNodeMap ()
 
void clearState ()
 
void insertCopiedNodePair (const SgNode *key, SgNode *value)
 

Member Typedef Documentation

◆ copiedNodeMapType

typedef std::map<const SgNode*,SgNode*> SgCopyHelp::copiedNodeMapType

Definition at line 29 of file sageCopy.h.

◆ copiedNodeMapTypeIterator

typedef copiedNodeMapType::iterator SgCopyHelp::copiedNodeMapTypeIterator

Definition at line 43 of file sageCopy.h.

Constructor & Destructor Documentation

◆ SgCopyHelp()

SgCopyHelp::SgCopyHelp ( )
inline

Definition at line 48 of file sageCopy.h.

◆ ~SgCopyHelp()

virtual SgCopyHelp::~SgCopyHelp ( )
inlinevirtual

Definition at line 51 of file sageCopy.h.

Member Function Documentation

◆ get_depth()

int SgCopyHelp::get_depth ( )
inline

Definition at line 54 of file sageCopy.h.

◆ incrementDepth()

void SgCopyHelp::incrementDepth ( )
inline

Definition at line 55 of file sageCopy.h.

◆ decrementDepth()

void SgCopyHelp::decrementDepth ( )
inline

Definition at line 56 of file sageCopy.h.

◆ get_copiedNodeMap()

copiedNodeMapType & SgCopyHelp::get_copiedNodeMap ( )
inline

Definition at line 57 of file sageCopy.h.

◆ clearState()

void SgCopyHelp::clearState ( )
inline

Definition at line 60 of file sageCopy.h.


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