ROSE  0.9.6a
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
sg Namespace Reference

Classes

struct  ScopeSetter
 Functor setting the scope of a sage node to a specified (at Functor construction time) scope. More...
 
struct  VarRefBuilder
 Functor building a variable reference from an initialized name. More...
 
struct  InitNameCloner
 Functor copying an initialized name into a different scope. More...
 
struct  SageInserter
 Generic inserter for sage containers. More...
 
struct  ConstLike
 projects the constness of T1 on T2 More...
 
struct  ConstLike< const T1, T2 >
 
struct  DispatchHandler
 
struct  VisitDispatcher
 implementation for dispatcher objects ( invokes roseVisitor.handle(sgnode) ) More...
 
struct  VisitDispatcher< T * >
 implementation for dispatcher pointers ( invokes roseVisitor->handle(sgnode) ) More...
 
struct  DefaultHandler
 
struct  AncestorTypeFinder
 helper class for _ancestor More...
 
struct  TypeRecoveryHandler
 

Functions

template<class SageNode >
static SageNode * cloneNode (const SageNode *n)
 returns a deep copy of a sage node More...
 
static void _append (SgExprListExp &container, SgExpression *elem)
 unified interface for storing an element in a sage container More...
 
static void _append (SgFunctionParameterList &container, SgInitializedName *elem)
 
template<class SageSequenceContainer >
SageInserter
< SageSequenceContainer > 
sage_inserter (SageSequenceContainer &cont)
 generates a SageInserter, adding elements at the end of a sequence More...
 
template<class T >
static void unused (const T &)
 portable implementation to avoid compiler warnings for unused parameter. More...
 
template<class T >
T & deref (T *ptr)
 dereferences an object (= checked dereference in debug mode) More...
 
static void unexpected_node (const SgNode &n)
 
template<class SageNode >
static SageNode & assume_sage_type (SgNode &n)
 unchecked down cast from SgNode to SageNode More...
 
template<class SageNode >
static const SageNode & assume_sage_type (const SgNode &n)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
template<class RoseVisitor , class SageNode >
static RoseVisitor _dispatch (RoseVisitor rv, SageNode *n)
 for internal use (use dispatch instead) More...
 
template<class RoseVisitor >
RoseVisitor dispatch (const RoseVisitor &rv, SgNode *n)
 uncovers the type of SgNode and passes it to an overloaded function handle in RoseVisitor. More...
 
template<class RoseVisitor >
RoseVisitor dispatch (const RoseVisitor &rv, const SgNode *n)
 
template<class AncestorNode , class QualSgNode >
AncestorNode * _ancestor (QualSgNode &n)
 implements the ancestor search More...
 
template<class AncestorNode >
AncestorNode * ancestor (SgNode *n)
 finds an ancestor node with a given type More...
 
template<class AncestorNode >
const AncestorNode * ancestor (const SgNode *n)
 
template<class AncestorNode >
AncestorNode & ancestor (SgNode &n)
 
template<class AncestorNode >
const AncestorNode & ancestor (const SgNode &n)
 
template<class SageNode >
SageNode * assert_sage_type (SgNode *n)
 asserts that n has type SageNode More...
 
template<class SageNode >
const SageNode * assert_sage_type (const SgNode *n)
 
static void swap_parent (SgNode *lhs, SgNode *rhs)
 swaps the parent pointer of two nodes More...
 
static void swap_parent (void *, void *)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
template<class SageNode , class SageChild >
void swap_child (SageNode &lhs, SageNode &rhs, SageChild *(SageNode::*getter)() const, void(SageNode::*setter)(SageChild *))
 swaps children (of equal kind) between two ancestor nodes of the same type More...
 

Function Documentation

template<class SageNode >
static SageNode* sg::cloneNode ( const SageNode *  n)
inlinestatic

returns a deep copy of a sage node

allows NULL input nodes (in contrast to SageInterface::deepCopy)

Definition at line 21 of file sageFunctors.h.

References SageInterface::deepCopy().

Referenced by sg::InitNameCloner::operator()().

static void sg::_append ( SgExprListExp container,
SgExpression elem 
)
inlinestatic

unified interface for storing an element in a sage container

Note
internal use

Definition at line 31 of file sageFunctors.h.

References SageInterface::appendExpression().

Referenced by sg::SageInserter< SageSequenceContainer >::operator=().

static void sg::_append ( SgFunctionParameterList container,
SgInitializedName elem 
)
inlinestatic

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Definition at line 38 of file sageFunctors.h.

References SageInterface::appendArg().

template<class SageSequenceContainer >
SageInserter<SageSequenceContainer> sg::sage_inserter ( SageSequenceContainer &  cont)

generates a SageInserter, adding elements at the end of a sequence

Template Parameters
SageSequenceContainer,asage container that supports appending an element

Definition at line 137 of file sageFunctors.h.

template<class T >
static void sg::unused ( const T &  )
inlinestatic

portable implementation to avoid compiler warnings for unused parameter.

Definition at line 33 of file sageGeneric.h.

Referenced by SgAsmPEFileHeader::dump(), rose::stringify_boost_edge_dbg_data_t(), rose::stringify_boost_graph_dbg_data_t(), rose::stringify_boost_vertex_callgraph_t(), rose::stringify_boost_vertex_classhierarchy_t(), rose::stringify_boost_vertex_dbg_data_t(), rose::stringify_controlEnum(), rose::stringify_defaultEnumFunctionType(), rose::stringify_language_enum(), rose::stringify_omp_sched_t(), rose::stringify_ops(), rose::stringify_ssa_unfiltered_cfgReachingDefType(), rose::stringify_yytokentype(), rose::stringifyAbstractMemoryObjectIndexSetIndex_type(), rose::stringifyArmInstructionCondition(), rose::stringifyArmInstructionKind(), rose::stringifyArmProgramStatusRegister(), rose::stringifyArmRegisterClass(), rose::stringifyArmSignForExpressionUnparsing(), rose::stringifyAsmUnparserOrganization(), rose::stringifyAssemblerEncodingType(), rose::stringifyAssemblerX86MemoryReferencePattern(), rose::stringifyAssemblerX86OperandDefn(), rose::stringifyAssociativitySpecifier(), rose::stringifyAST_Graph_pointerHandling(), rose::stringifyAST_Graph_traversalType(), rose::stringifyAstAttributeDOT_DOTStyles(), rose::stringifyAstDisplayInfoNodeType(), rose::stringifyAstQueryNamespaceQueryDepth(), rose::stringifyAstUnparseAttributeRelativePositionType(), rose::stringifyBaseGraphBiDirNodesIterator_dirType(), rose::stringifyBinaryAnalysisDwarfLineMapperDirection(), rose::stringifyBinaryAnalysisInstructionSemantics2IntervalSemanticsCarry(), rose::stringifyBinaryAnalysisInstructionSemanticsIntervalSemanticsPolicyCarry(), rose::stringifyBinaryAnalysisInstructionSemanticsPartialSymbolicSemanticsPolicyMemRefType(), rose::stringifyBinaryAnalysisPointerAnalysisPointerType(), rose::stringifyBinaryCallingConventionConventionParameterOrder(), rose::stringifyBinaryCallingConventionConventionReturnValueLocation(), rose::stringifyBinaryCallingConventionConventionStackCleanup(), rose::stringifyBinaryCallingConventionConventionThisPointerLocation(), rose::stringifyBinaryLoaderConflictResolution(), rose::stringifyBinaryLoaderMappingContribution(), rose::stringifyBooleanQueryTypeOfQueryType(), rose::stringifyBuildAccess_EnumX(), rose::stringifyByteOrderEndianness(), rose::stringifyCallGraphEdgeType(), rose::stringifyCFG_EdgeType(), rose::stringifyCGFunction_iterator_direction(), rose::stringifyClangToSageTranslatorLanguage(), rose::stringifyCollectAliasRelationsCOLOR(), rose::stringifyCollectAliasRelationsTRAVERSAL_TYPE(), rose::stringifyCompilerOutputWidgetPatternType(), rose::stringifyConstrGraph_levels(), rose::stringifyConstructParam_EnumX(), rose::stringifyCopyConfig_EnumX(), rose::stringifyCxx_GrammarVariants(), rose::stringifyDependencyInfoState(), rose::stringifyDisassemblerMipsMips32Architecture(), rose::stringifyDisassemblerSearchHeuristic(), rose::stringifyDisassemblerX86MMPrefix(), rose::stringifyDisassemblerX86RegisterMode(), rose::stringifyDisplayEdgePaintMode(), rose::stringifyDominatorTreesAndDominanceFrontiersDir_ection(), rose::stringifyDominatorTreesAndDominanceFrontiersDominatorTreeDirection(), rose::stringifyDOTGraphEdgeDOTArrowTypes(), rose::stringifyDOTGraphNodeDOTShapeTypes(), rose::stringifyE_SgActualArgumentExpression(), rose::stringifyE_SgAddOp(), rose::stringifyE_SgAddressOfOp(), rose::stringifyE_SgAggregateInitializer(), rose::stringifyE_SgAliasSymbol(), rose::stringifyE_SgAlignOfOp(), rose::stringifyE_SgAllocateStatement(), rose::stringifyE_SgAndAssignOp(), rose::stringifyE_SgAndOp(), rose::stringifyE_SgArithmeticIfStatement(), rose::stringifyE_SgArrayType(), rose::stringifyE_SgArrowExp(), rose::stringifyE_SgArrowStarOp(), rose::stringifyE_SgAsmArmInstruction(), rose::stringifyE_SgAsmBinaryAdd(), rose::stringifyE_SgAsmBinaryAddPostupdate(), rose::stringifyE_SgAsmBinaryAddPreupdate(), rose::stringifyE_SgAsmBinaryAsr(), rose::stringifyE_SgAsmBinaryDivide(), rose::stringifyE_SgAsmBinaryExpression(), rose::stringifyE_SgAsmBinaryLsl(), rose::stringifyE_SgAsmBinaryLsr(), rose::stringifyE_SgAsmBinaryMod(), rose::stringifyE_SgAsmBinaryMultiply(), rose::stringifyE_SgAsmBinaryRor(), rose::stringifyE_SgAsmBinarySubtract(), rose::stringifyE_SgAsmBinarySubtractPostupdate(), rose::stringifyE_SgAsmBinarySubtractPreupdate(), rose::stringifyE_SgAsmBlock(), rose::stringifyE_SgAsmCoffSymbol(), rose::stringifyE_SgAsmCoffSymbolList(), rose::stringifyE_SgAsmCoffSymbolTable(), rose::stringifyE_SgAsmCommonSubExpression(), rose::stringifyE_SgAsmDOSFileHeader(), rose::stringifyE_SgAsmDoubleFloatValueExpression(), rose::stringifyE_SgAsmDwarfArrayType(), rose::stringifyE_SgAsmDwarfClassType(), rose::stringifyE_SgAsmDwarfCommonBlock(), rose::stringifyE_SgAsmDwarfCompilationUnit(), rose::stringifyE_SgAsmDwarfCompilationUnitList(), rose::stringifyE_SgAsmDwarfConstructList(), rose::stringifyE_SgAsmDwarfEnumerationType(), rose::stringifyE_SgAsmDwarfInlinedSubroutine(), rose::stringifyE_SgAsmDwarfLexicalBlock(), rose::stringifyE_SgAsmDwarfLineList(), rose::stringifyE_SgAsmDwarfMacroList(), rose::stringifyE_SgAsmDwarfNamespace(), rose::stringifyE_SgAsmDwarfStructureType(), rose::stringifyE_SgAsmDwarfSubprogram(), rose::stringifyE_SgAsmDwarfSubroutineType(), rose::stringifyE_SgAsmDwarfUnionType(), rose::stringifyE_SgAsmElfDynamicEntry(), rose::stringifyE_SgAsmElfDynamicSection(), rose::stringifyE_SgAsmElfEHFrameEntryCI(), rose::stringifyE_SgAsmElfEHFrameSection(), rose::stringifyE_SgAsmElfFileHeader(), rose::stringifyE_SgAsmElfNoteEntry(), rose::stringifyE_SgAsmElfNoteSection(), rose::stringifyE_SgAsmElfRelocEntryList(), rose::stringifyE_SgAsmElfRelocSection(), rose::stringifyE_SgAsmElfSection(), rose::stringifyE_SgAsmElfSegmentTableEntryList(), rose::stringifyE_SgAsmElfStringSection(), rose::stringifyE_SgAsmElfSymbol(), rose::stringifyE_SgAsmElfSymbolList(), rose::stringifyE_SgAsmElfSymbolSection(), rose::stringifyE_SgAsmElfSymverDefinedAux(), rose::stringifyE_SgAsmElfSymverDefinedAuxList(), rose::stringifyE_SgAsmElfSymverDefinedEntry(), rose::stringifyE_SgAsmElfSymverDefinedEntryList(), rose::stringifyE_SgAsmElfSymverDefinedSection(), rose::stringifyE_SgAsmElfSymverEntryList(), rose::stringifyE_SgAsmElfSymverNeededAux(), rose::stringifyE_SgAsmElfSymverNeededAuxList(), rose::stringifyE_SgAsmElfSymverNeededEntry(), rose::stringifyE_SgAsmElfSymverNeededEntryList(), rose::stringifyE_SgAsmElfSymverNeededSection(), rose::stringifyE_SgAsmElfSymverSection(), rose::stringifyE_SgAsmExprListExp(), rose::stringifyE_SgAsmFunction(), rose::stringifyE_SgAsmGenericDLL(), rose::stringifyE_SgAsmGenericFile(), rose::stringifyE_SgAsmGenericFileList(), rose::stringifyE_SgAsmGenericHeader(), rose::stringifyE_SgAsmGenericHeaderList(), rose::stringifyE_SgAsmGenericSectionList(), rose::stringifyE_SgAsmGenericSymbol(), rose::stringifyE_SgAsmInstruction(), rose::stringifyE_SgAsmIntegerValueExpression(), rose::stringifyE_SgAsmInterpretation(), rose::stringifyE_SgAsmInterpretationList(), rose::stringifyE_SgAsmLEEntryPoint(), rose::stringifyE_SgAsmLEEntryTable(), rose::stringifyE_SgAsmLEFileHeader(), rose::stringifyE_SgAsmLEPageTable(), rose::stringifyE_SgAsmLERelocTable(), rose::stringifyE_SgAsmLESection(), rose::stringifyE_SgAsmMemoryReferenceExpression(), rose::stringifyE_SgAsmMipsInstruction(), rose::stringifyE_SgAsmNEEntryTable(), rose::stringifyE_SgAsmNEFileHeader(), rose::stringifyE_SgAsmNEModuleTable(), rose::stringifyE_SgAsmNERelocTable(), rose::stringifyE_SgAsmNESection(), rose::stringifyE_SgAsmOp(), rose::stringifyE_SgAsmOperandList(), rose::stringifyE_SgAsmPEExportDirectory(), rose::stringifyE_SgAsmPEExportEntry(), rose::stringifyE_SgAsmPEExportEntryList(), rose::stringifyE_SgAsmPEExportSection(), rose::stringifyE_SgAsmPEFileHeader(), rose::stringifyE_SgAsmPEImportDirectory(), rose::stringifyE_SgAsmPEImportDirectoryList(), rose::stringifyE_SgAsmPEImportItem(), rose::stringifyE_SgAsmPEImportItemList(), rose::stringifyE_SgAsmPEImportSection(), rose::stringifyE_SgAsmPERVASizePairList(), rose::stringifyE_SgAsmPESection(), rose::stringifyE_SgAsmPEStringSection(), rose::stringifyE_SgAsmPowerpcInstruction(), rose::stringifyE_SgAsmSingleFloatValueExpression(), rose::stringifyE_SgAsmStmt(), rose::stringifyE_SgAsmType128bitFloat(), rose::stringifyE_SgAsmType80bitFloat(), rose::stringifyE_SgAsmTypeByte(), rose::stringifyE_SgAsmTypeDoubleFloat(), rose::stringifyE_SgAsmTypeDoubleQuadWord(), rose::stringifyE_SgAsmTypeDoubleWord(), rose::stringifyE_SgAsmTypeQuadWord(), rose::stringifyE_SgAsmTypeSingleFloat(), rose::stringifyE_SgAsmTypeWord(), rose::stringifyE_SgAsmUnaryArmSpecialRegisterList(), rose::stringifyE_SgAsmUnaryExpression(), rose::stringifyE_SgAsmUnaryMinus(), rose::stringifyE_SgAsmUnaryPlus(), rose::stringifyE_SgAsmUnaryRrx(), rose::stringifyE_SgAsmValueExpression(), rose::stringifyE_SgAsmx86Instruction(), rose::stringifyE_SgAssertStmt(), rose::stringifyE_SgAssignedGotoStatement(), rose::stringifyE_SgAssignInitializer(), rose::stringifyE_SgAssignOp(), rose::stringifyE_SgAssignStatement(), rose::stringifyE_SgAssociateStatement(), rose::stringifyE_SgBackspaceStatement(), rose::stringifyE_SgBaseClass(), rose::stringifyE_SgBasicBlock(), rose::stringifyE_SgBinaryComposite(), rose::stringifyE_SgBinaryOp(), rose::stringifyE_SgBitAndOp(), rose::stringifyE_SgBitComplementOp(), rose::stringifyE_SgBitOrOp(), rose::stringifyE_SgBitXorOp(), rose::stringifyE_SgCAFCoExpression(), rose::stringifyE_SgCAFWithTeamStatement(), rose::stringifyE_SgCallExpression(), rose::stringifyE_SgCaseOptionStmt(), rose::stringifyE_SgCastExp(), rose::stringifyE_SgCatchOptionStmt(), rose::stringifyE_SgCatchStatementSeq(), rose::stringifyE_SgClassDeclaration(), rose::stringifyE_SgClassDefinition(), rose::stringifyE_SgClassSymbol(), rose::stringifyE_SgClassType(), rose::stringifyE_SgCloseStatement(), rose::stringifyE_SgCommaOpExp(), rose::stringifyE_SgCommonBlock(), rose::stringifyE_SgCommonBlockObject(), rose::stringifyE_SgComplexVal(), rose::stringifyE_SgCompoundAssignOp(), rose::stringifyE_SgCompoundInitializer(), rose::stringifyE_SgComprehension(), rose::stringifyE_SgComputedGotoStatement(), rose::stringifyE_SgConcatenationOp(), rose::stringifyE_SgConditionalExp(), rose::stringifyE_SgConjugateOp(), rose::stringifyE_SgConstructorInitializer(), rose::stringifyE_SgCtorInitializerList(), rose::stringifyE_SgCudaKernelCallExp(), rose::stringifyE_SgCudaKernelExecConfig(), rose::stringifyE_SgDeallocateStatement(), rose::stringifyE_SgDefaultOptionStmt(), rose::stringifyE_SgDeleteExp(), rose::stringifyE_SgDerivedTypeStatement(), rose::stringifyE_SgDesignatedInitializer(), rose::stringifyE_SgDictionaryComprehension(), rose::stringifyE_SgDictionaryExp(), rose::stringifyE_SgDirectory(), rose::stringifyE_SgDirectoryList(), rose::stringifyE_SgDivAssignOp(), rose::stringifyE_SgDivideOp(), rose::stringifyE_SgDotExp(), rose::stringifyE_SgDotStarOp(), rose::stringifyE_SgDoWhileStmt(), rose::stringifyE_SgElseWhereStatement(), rose::stringifyE_SgEndfileStatement(), rose::stringifyE_SgEntryStatement(), rose::stringifyE_SgEnumDeclaration(), rose::stringifyE_SgEnumSymbol(), rose::stringifyE_SgEnumType(), rose::stringifyE_SgEqualityOp(), rose::stringifyE_SgExecStatement(), rose::stringifyE_SgExpBaseClass(), rose::stringifyE_SgExponentiationAssignOp(), rose::stringifyE_SgExponentiationOp(), rose::stringifyE_SgExpressionRoot(), rose::stringifyE_SgExprListExp(), rose::stringifyE_SgExprStatement(), rose::stringifyE_SgFileList(), rose::stringifyE_SgFlushStatement(), rose::stringifyE_SgForAllStatement(), rose::stringifyE_SgForInitStatement(), rose::stringifyE_SgForStatement(), rose::stringifyE_SgFortranDo(), rose::stringifyE_SgFortranNonblockedDo(), rose::stringifyE_SgFunctionCallExp(), rose::stringifyE_SgFunctionDeclaration(), rose::stringifyE_SgFunctionDefinition(), rose::stringifyE_SgFunctionParameterList(), rose::stringifyE_SgFunctionSymbol(), rose::stringifyE_SgFunctionType(), rose::stringifyE_SgGlobal(), rose::stringifyE_SgGreaterOrEqualOp(), rose::stringifyE_SgGreaterThanOp(), rose::stringifyE_SgIfStmt(), rose::stringifyE_SgImagPartOp(), rose::stringifyE_SgImplicitStatement(), rose::stringifyE_SgImpliedDo(), rose::stringifyE_SgIncludeDirectiveStatement(), rose::stringifyE_SgInitializedName(), rose::stringifyE_SgInquireStatement(), rose::stringifyE_SgIntegerDivideAssignOp(), rose::stringifyE_SgIntegerDivideOp(), rose::stringifyE_SgInterfaceStatement(), rose::stringifyE_SgIOItemExpression(), rose::stringifyE_SgIorAssignOp(), rose::stringifyE_SgIOStatement(), rose::stringifyE_SgIsNotOp(), rose::stringifyE_SgIsOp(), rose::stringifyE_SgJavaClassDeclarationList(), rose::stringifyE_SgJavaForEachStatement(), rose::stringifyE_SgJavaImportStatementList(), rose::stringifyE_SgJavaInstanceOfOp(), rose::stringifyE_SgJavaLabelStatement(), rose::stringifyE_SgJavaLabelSymbol(), rose::stringifyE_SgJavaMemberValuePair(), rose::stringifyE_SgJavaNormalAnnotation(), rose::stringifyE_SgJavaPackageDeclaration(), rose::stringifyE_SgJavaParameterizedType(), rose::stringifyE_SgJavaParameterType(), rose::stringifyE_SgJavaQualifiedType(), rose::stringifyE_SgJavaSingleMemberAnnotation(), rose::stringifyE_SgJavaSynchronizedStatement(), rose::stringifyE_SgJavaUnionType(), rose::stringifyE_SgJavaUnsignedRshiftAssignOp(), rose::stringifyE_SgJavaUnsignedRshiftOp(), rose::stringifyE_SgJavaWildcardType(), rose::stringifyE_SgKeyDatumPair(), rose::stringifyE_SgLabelSymbol(), rose::stringifyE_SgLambdaRefExp(), rose::stringifyE_SgLessOrEqualOp(), rose::stringifyE_SgLessThanOp(), rose::stringifyE_SgListComprehension(), rose::stringifyE_SgListExp(), rose::stringifyE_SgLshiftAssignOp(), rose::stringifyE_SgLshiftOp(), rose::stringifyE_SgMemberFunctionDeclaration(), rose::stringifyE_SgMemberFunctionSymbol(), rose::stringifyE_SgMemberFunctionType(), rose::stringifyE_SgMembershipOp(), rose::stringifyE_SgMinusAssignOp(), rose::stringifyE_SgMinusMinusOp(), rose::stringifyE_SgMinusOp(), rose::stringifyE_SgModAssignOp(), rose::stringifyE_SgModifierType(), rose::stringifyE_SgModOp(), rose::stringifyE_SgModuleStatement(), rose::stringifyE_SgModuleSymbol(), rose::stringifyE_SgMultAssignOp(), rose::stringifyE_SgMultiplyOp(), rose::stringifyE_SgNamedType(), rose::stringifyE_SgNamespaceDeclarationStatement(), rose::stringifyE_SgNamespaceDefinitionStatement(), rose::stringifyE_SgNamespaceSymbol(), rose::stringifyE_SgNaryBooleanOp(), rose::stringifyE_SgNaryComparisonOp(), rose::stringifyE_SgNaryOp(), rose::stringifyE_SgNewExp(), rose::stringifyE_SgNonMembershipOp(), rose::stringifyE_SgNotEqualOp(), rose::stringifyE_SgNotOp(), rose::stringifyE_SgNullifyStatement(), rose::stringifyE_SgOmpAlignedClause(), rose::stringifyE_SgOmpAtomicStatement(), rose::stringifyE_SgOmpBodyStatement(), rose::stringifyE_SgOmpClauseBodyStatement(), rose::stringifyE_SgOmpCollapseClause(), rose::stringifyE_SgOmpCopyinClause(), rose::stringifyE_SgOmpCopyprivateClause(), rose::stringifyE_SgOmpCriticalStatement(), rose::stringifyE_SgOmpDeviceClause(), rose::stringifyE_SgOmpDoStatement(), rose::stringifyE_SgOmpExpressionClause(), rose::stringifyE_SgOmpFirstprivateClause(), rose::stringifyE_SgOmpFlushStatement(), rose::stringifyE_SgOmpForStatement(), rose::stringifyE_SgOmpIfClause(), rose::stringifyE_SgOmpLastprivateClause(), rose::stringifyE_SgOmpLinearClause(), rose::stringifyE_SgOmpMapClause(), rose::stringifyE_SgOmpMasterStatement(), rose::stringifyE_SgOmpNumThreadsClause(), rose::stringifyE_SgOmpOrderedStatement(), rose::stringifyE_SgOmpParallelStatement(), rose::stringifyE_SgOmpPrivateClause(), rose::stringifyE_SgOmpReductionClause(), rose::stringifyE_SgOmpSafelenClause(), rose::stringifyE_SgOmpScheduleClause(), rose::stringifyE_SgOmpSectionsStatement(), rose::stringifyE_SgOmpSectionStatement(), rose::stringifyE_SgOmpSharedClause(), rose::stringifyE_SgOmpSimdStatement(), rose::stringifyE_SgOmpSingleStatement(), rose::stringifyE_SgOmpTargetDataStatement(), rose::stringifyE_SgOmpTargetStatement(), rose::stringifyE_SgOmpTaskStatement(), rose::stringifyE_SgOmpThreadprivateStatement(), rose::stringifyE_SgOmpUniformClause(), rose::stringifyE_SgOmpVariablesClause(), rose::stringifyE_SgOmpWorkshareStatement(), rose::stringifyE_SgOpenStatement(), rose::stringifyE_SgOrOp(), rose::stringifyE_SgPartialFunctionModifierType(), rose::stringifyE_SgPartialFunctionType(), rose::stringifyE_SgPlusAssignOp(), rose::stringifyE_SgPlusPlusOp(), rose::stringifyE_SgPntrArrRefExp(), rose::stringifyE_SgPointerAssignOp(), rose::stringifyE_SgPointerDerefExp(), rose::stringifyE_SgPointerMemberType(), rose::stringifyE_SgPointerType(), rose::stringifyE_SgPragmaDeclaration(), rose::stringifyE_SgPrintStatement(), rose::stringifyE_SgProcedureHeaderStatement(), rose::stringifyE_SgProgramHeaderStatement(), rose::stringifyE_SgProject(), rose::stringifyE_SgPythonGlobalStmt(), rose::stringifyE_SgPythonPrintStmt(), rose::stringifyE_SgQualifiedNameType(), rose::stringifyE_SgReadStatement(), rose::stringifyE_SgRealPartOp(), rose::stringifyE_SgReferenceType(), rose::stringifyE_SgRenameSymbol(), rose::stringifyE_SgReturnStmt(), rose::stringifyE_SgRewindStatement(), rose::stringifyE_SgRshiftAssignOp(), rose::stringifyE_SgRshiftOp(), rose::stringifyE_SgScopeOp(), rose::stringifyE_SgSetComprehension(), rose::stringifyE_SgSizeOfOp(), rose::stringifyE_SgSourceFile(), rose::stringifyE_SgSpawnStmt(), rose::stringifyE_SgStatementExpression(), rose::stringifyE_SgStatementFunctionStatement(), rose::stringifyE_SgStmtDeclarationStatement(), rose::stringifyE_SgStringConversion(), rose::stringifyE_SgSubscriptExpression(), rose::stringifyE_SgSubtractOp(), rose::stringifyE_SgSwitchStatement(), rose::stringifyE_SgTemplateArgument(), rose::stringifyE_SgTemplateArgumentList(), rose::stringifyE_SgTemplateClassDeclaration(), rose::stringifyE_SgTemplateClassDefinition(), rose::stringifyE_SgTemplateClassSymbol(), rose::stringifyE_SgTemplateFunctionDeclaration(), rose::stringifyE_SgTemplateFunctionDefinition(), rose::stringifyE_SgTemplateFunctionSymbol(), rose::stringifyE_SgTemplateInstantiationDecl(), rose::stringifyE_SgTemplateInstantiationDefn(), rose::stringifyE_SgTemplateInstantiationDirectiveStatement(), rose::stringifyE_SgTemplateInstantiationFunctionDecl(), rose::stringifyE_SgTemplateInstantiationMemberFunctionDecl(), rose::stringifyE_SgTemplateMemberFunctionDeclaration(), rose::stringifyE_SgTemplateMemberFunctionSymbol(), rose::stringifyE_SgTemplateParameter(), rose::stringifyE_SgTemplateParameterList(), rose::stringifyE_SgTemplateSymbol(), rose::stringifyE_SgTemplateType(), rose::stringifyE_SgTemplateVariableDeclaration(), rose::stringifyE_SgThrowOp(), rose::stringifyE_SgTryStmt(), rose::stringifyE_SgTupleExp(), rose::stringifyE_SgType(), rose::stringifyE_SgTypeBool(), rose::stringifyE_SgTypeCAFTeam(), rose::stringifyE_SgTypeChar(), rose::stringifyE_SgTypeComplex(), rose::stringifyE_SgTypeCrayPointer(), rose::stringifyE_SgTypeDefault(), rose::stringifyE_SgTypedefDeclaration(), rose::stringifyE_SgTypedefSymbol(), rose::stringifyE_SgTypedefType(), rose::stringifyE_SgTypeDouble(), rose::stringifyE_SgTypeEllipse(), rose::stringifyE_SgTypeFloat(), rose::stringifyE_SgTypeGlobalVoid(), rose::stringifyE_SgTypeIdOp(), rose::stringifyE_SgTypeImaginary(), rose::stringifyE_SgTypeInt(), rose::stringifyE_SgTypeLabel(), rose::stringifyE_SgTypeLong(), rose::stringifyE_SgTypeLongDouble(), rose::stringifyE_SgTypeLongLong(), rose::stringifyE_SgTypeShort(), rose::stringifyE_SgTypeSigned128bitInteger(), rose::stringifyE_SgTypeSignedChar(), rose::stringifyE_SgTypeSignedInt(), rose::stringifyE_SgTypeSignedLong(), rose::stringifyE_SgTypeSignedLongLong(), rose::stringifyE_SgTypeSignedShort(), rose::stringifyE_SgTypeString(), rose::stringifyE_SgTypeUnknown(), rose::stringifyE_SgTypeUnsigned128bitInteger(), rose::stringifyE_SgTypeUnsignedChar(), rose::stringifyE_SgTypeUnsignedInt(), rose::stringifyE_SgTypeUnsignedLong(), rose::stringifyE_SgTypeUnsignedLongLong(), rose::stringifyE_SgTypeUnsignedShort(), rose::stringifyE_SgTypeVoid(), rose::stringifyE_SgTypeWchar(), rose::stringifyE_SgUnaryAddOp(), rose::stringifyE_SgUnaryOp(), rose::stringifyE_SgUnknownArrayOrFunctionReference(), rose::stringifyE_SgUnknownFile(), rose::stringifyE_SgUntypedDeclarationList(), rose::stringifyE_SgUntypedFunctionDeclaration(), rose::stringifyE_SgUntypedFunctionDeclarationList(), rose::stringifyE_SgUntypedFunctionScope(), rose::stringifyE_SgUntypedGlobalScope(), rose::stringifyE_SgUntypedInitializedNameList(), rose::stringifyE_SgUntypedModuleScope(), rose::stringifyE_SgUntypedProgramHeaderDeclaration(), rose::stringifyE_SgUntypedScope(), rose::stringifyE_SgUntypedStatementList(), rose::stringifyE_SgUntypedSubroutineDeclaration(), rose::stringifyE_SgUntypedVariableDeclaration(), rose::stringifyE_SgUpcBarrierStatement(), rose::stringifyE_SgUpcBlocksizeofExpression(), rose::stringifyE_SgUpcElemsizeofExpression(), rose::stringifyE_SgUpcForAllStatement(), rose::stringifyE_SgUpcLocalsizeofExpression(), rose::stringifyE_SgUpcNotifyStatement(), rose::stringifyE_SgUpcWaitStatement(), rose::stringifyE_SgUserDefinedBinaryOp(), rose::stringifyE_SgUserDefinedUnaryOp(), rose::stringifyE_SgUseStatement(), rose::stringifyE_SgVarArgCopyOp(), rose::stringifyE_SgVarArgEndOp(), rose::stringifyE_SgVarArgOp(), rose::stringifyE_SgVarArgStartOneOperandOp(), rose::stringifyE_SgVarArgStartOp(), rose::stringifyE_SgVariableDeclaration(), rose::stringifyE_SgVariableDefinition(), rose::stringifyE_SgWaitStatement(), rose::stringifyE_SgWhereStatement(), rose::stringifyE_SgWhileStmt(), rose::stringifyE_SgWithStatement(), rose::stringifyE_SgWriteStatement(), rose::stringifyE_SgXorAssignOp(), rose::stringifyE_SgYieldExpression(), rose::stringifyFailSafe_fail_safe_enum(), rose::stringifyFormat_Opt(), rose::stringifyFunctionCallInfoInsertionMode(), rose::stringifyGenRepresentationTypeOfPrint(), rose::stringifyHighLevelCollectionTypedefsIntermediateFileStringPosition_Enum(), rose::stringifyHighLevelCollectionTypedefsPlacementPosition_Enum(), rose::stringifyHighLevelCollectionTypedefsScopeIdentifier_Enum(), rose::stringifyInsnSemanticsExprFormatterShowComments(), rose::stringifyInsnSemanticsExprLeafNodeLeafType(), rose::stringifyInsnSemanticsExprOperator(), rose::stringifyInsnSemanticsExprVisitAction(), rose::stringifyIRProcType(), rose::stringifyIRStmtType(), rose::stringifyMatchStatusCheckNodeMode(), rose::stringifyMatchStatusPatternMatchMode(), rose::stringifyMemoryMapCopyLevel(), rose::stringifyMemoryMapProtection(), rose::stringifyMidLevelCollectionTypedefsIntermediateFileStringPosition_Enum(), rose::stringifyMidLevelCollectionTypedefsPlacementPosition_Enum(), rose::stringifyMidLevelCollectionTypedefsScopeIdentifier_Enum(), rose::stringifyMipsFcsrMinors(), rose::stringifyMipsInstructionKind(), rose::stringifyMipsRegisterClass(), rose::stringifyMipsSpecialPurposeRegister(), rose::stringifyNameQueryTypeOfQueryTypeOneParameter(), rose::stringifyNameQueryTypeOfQueryTypeTwoParameters(), rose::stringifyNFAAssertion(), rose::stringifyNFAType(), rose::stringifyNodeQueryTypeOfQueryTypeOneParameter(), rose::stringifyNodeQueryTypeOfQueryTypeTwoParameters(), rose::stringifyNumberQueryTypeOfQueryTypeOneParameter(), rose::stringifyNumberQueryTypeOfQueryTypeTwoParameters(), rose::stringifyOmpSupport_omp_construct_enum(), rose::stringifyOmpSupport_omp_rtl_enum(), rose::stringifyPartitionerRegionStatsAnalysisEnum(), rose::stringifyPowerpcConditionRegisterAccessGranularity(), rose::stringifyPowerpcInstructionKind(), rose::stringifyPowerpcRegisterClass(), rose::stringifyPowerpcSpecialPurposeRegister(), rose::stringifyPowerpcTimeBaseRegister(), rose::stringifyPreprocessingInfoDirectiveType(), rose::stringifyPreprocessingInfoRelativePositionType(), rose::stringifyPtrAliasAnalysisCOLOR(), rose::stringifyPtrAliasAnalysisTRAVERSAL_TYPE(), rose::stringifyQCodeEditPosition(), rose::stringifyQDocumentCommandCommand(), rose::stringifyQDocumentCursorHandleFlags(), rose::stringifyQDocumentCursorMoveFlag(), rose::stringifyQDocumentCursorMoveOperation(), rose::stringifyQDocumentCursorSelectionType(), rose::stringifyQDocumentLineEnding(), rose::stringifyQDocumentLineState(), rose::stringifyQDocumentSearchOption(), rose::stringifyQDocumentTextProcessing(), rose::stringifyQDocumentWhiteSpaceFlag(), rose::stringifyQEditorCodecUpdatePolicy(), rose::stringifyQEditorEditFlag(), rose::stringifyQEditorSaveState(), rose::stringifyQLanguageDefinitionCollapseFlag(), rose::stringifyQNFAActionQNFAAction_(), rose::stringifyQNFADefinitionPMatchType(), rose::stringifyQPanelLayoutPosition(), rose::stringifyQPanelLayoutSizeType(), rose::stringifyQParenthesisRole(), rose::stringifyQReliableFileWatchState(), rose::stringifyQtColorLineColorComponent(), rose::stringifyQtGradientWidgetPrivateHandle(), rose::stringifyReachingDefType(), rose::stringifyRegisterDictionarySortBySizeDirection(), rose::stringifyRIFG_EdgeDirection(), rose::stringifyRIFG_ForwardBackward(), rose::stringifyRITarjEdgeType(), rose::stringifyRITarjType(), rose::stringifyROSE_CallbacksDirection(), rose::stringifyROSE_Fortran_Additional_Info(), rose::stringifyROSE_Fortran_defsROSE_C_CXX_keywords(), rose::stringifyROSE_Fortran_defsROSE_C_CXX_operators(), rose::stringifyROSE_Fortran_defsROSE_Fortran_Additional_Info(), rose::stringifyROSE_Fortran_defsROSE_Fortran_keywords(), rose::stringifyROSE_Fortran_defsROSE_Fortran_Operators(), rose::stringifyROSE_Fortran_Identifiers(), rose::stringifyROSE_Fortran_Operators(), rose::stringifyROSE_token_ids_whitespace(), rose::stringifyROSE_token_idsROSE_C_CXX_Additional_Info(), rose::stringifyROSE_token_idsROSE_C_CXX_alternate_tok(), rose::stringifyROSE_token_idsROSE_C_CXX_keywords(), rose::stringifyROSEAttributesList_languageTypeEnum(), rose::stringifyRoseBin_ArchArchitecture(), rose::stringifyRoseBin_DataTypesDataTypes(), rose::stringifyRoseBin_DefRoseLanguage(), rose::stringifyRoseBin_OS_OSSYSTEM(), rose::stringifyRoseBin_OS_VER_OS_VERSION(), rose::stringifyRoseBin_supportX86PositionInRegister(), rose::stringifyRTS_Layer(), rose::stringifySageBuilderSourcePositionClassification(), rose::stringifySDG_PDGEdgeEdgeType(), rose::stringifySDG_SDGEdgeControlDependenceType(), rose::stringifySDG_SDGEdgeEdgeType(), rose::stringifySDG_SDGNodeNodeType(), rose::stringifySg_File_Info_classifier(), rose::stringifySg_File_Info_p_fileflags(), rose::stringifySgAccessModifier_access_modifier_enum(), rose::stringifySgAsmArmRegisterReferenceExpression_arm_suffix_field_enum(), rose::stringifySgAsmBlockReason(), rose::stringifySgAsmElfDynamicEntryEntryType(), rose::stringifySgAsmElfFileHeaderObjectType(), rose::stringifySgAsmElfRelocEntryRelocType(), rose::stringifySgAsmElfSectionTableEntrySectionFlags(), rose::stringifySgAsmElfSectionTableEntrySectionType(), rose::stringifySgAsmElfSegmentTableEntrySegmentFlags(), rose::stringifySgAsmElfSegmentTableEntrySegmentType(), rose::stringifySgAsmElfSymbolElfSymBinding(), rose::stringifySgAsmElfSymbolElfSymType(), rose::stringifySgAsmExecutableFileFormatExecABI(), rose::stringifySgAsmExecutableFileFormatExecFamily(), rose::stringifySgAsmExecutableFileFormatExecPurpose(), rose::stringifySgAsmExecutableFileFormatInsSetArchitecture(), rose::stringifySgAsmFunction_function_calling_convention_enum(), rose::stringifySgAsmFunction_function_kind_enum(), rose::stringifySgAsmFunctionFunctionReason(), rose::stringifySgAsmFunctionMayReturn(), rose::stringifySgAsmGenericFileAddressSpace(), rose::stringifySgAsmGenericFileElasticity(), rose::stringifySgAsmGenericSectionSectionPurpose(), rose::stringifySgAsmGenericSymbolSymbolBinding(), rose::stringifySgAsmGenericSymbolSymbolDefState(), rose::stringifySgAsmGenericSymbolSymbolType(), rose::stringifySgAsmLEFileHeaderLEFileHeaderFlags(), rose::stringifySgAsmLESectionTableEntryLESectionFlags(), rose::stringifySgAsmNEEntryPointNEEntryFlags(), rose::stringifySgAsmNEFileHeaderHeaderFlags1(), rose::stringifySgAsmNEFileHeaderHeaderFlags2(), rose::stringifySgAsmNERelocEntryNERelocFlags(), rose::stringifySgAsmNERelocEntryNERelocModifiers(), rose::stringifySgAsmNERelocEntryNERelocSrcType(), rose::stringifySgAsmNERelocEntryNERelocTgtType(), rose::stringifySgAsmNESectionTableEntryNESectionFlags(), rose::stringifySgAsmOp_asm_operand_constraint_enum(), rose::stringifySgAsmOp_asm_operand_modifier_enum(), rose::stringifySgAsmPEFileHeaderDLLFlags(), rose::stringifySgAsmPEFileHeaderHeaderFlags(), rose::stringifySgAsmPEFileHeaderPairPurpose(), rose::stringifySgAsmPEFileHeaderSubsystem(), rose::stringifySgAsmPESectionTableEntryPESectionFlags(), rose::stringifySgAsmx86RegisterReferenceExpression_regnames16_enum(), rose::stringifySgAsmx86RegisterReferenceExpression_regnames32_enum(), rose::stringifySgAsmx86RegisterReferenceExpression_regnames64_enum(), rose::stringifySgAsmx86RegisterReferenceExpression_regnames8h_enum(), rose::stringifySgAsmx86RegisterReferenceExpression_regnames8l_enum(), rose::stringifySgAsmx86RegisterReferenceExpression_segregnames_enum(), rose::stringifySgAttributeSpecificationStatement_attribute_spec_enum(), rose::stringifySgBaseClassModifier_baseclass_modifier_enum(), rose::stringifySgCastExp_cast_type_enum(), rose::stringifySgClassDeclaration_class_types(), rose::stringifySgConstVolatileModifier_cv_modifier_enum(), rose::stringifySgDataStatementValue_data_statement_value_enum(), rose::stringifySgDeclarationModifier_declaration_modifier_enum(), rose::stringifySgDeclarationModifier_gnu_declaration_visability_enum(), rose::stringifySgDeclarationStatement_gnu_extension_visability_attribute_enum(), rose::stringifySgDeclarationStatement_template_specialization_enum(), rose::stringifySgElaboratedTypeModifier_elaborated_type_modifier_enum(), rose::stringifySgFile_outputFormatOption_enum(), rose::stringifySgFile_outputLanguageOption_enum(), rose::stringifySgFunctionModifier_function_modifier_enum(), rose::stringifySgGraphGraphEdgeType(), rose::stringifySgGraphGraphProperties(), rose::stringifySgInitializedName_asm_register_name_enum(), rose::stringifySgInitializedName_excess_specifier_enum(), rose::stringifySgInitializedName_gnu_variable_attribute_enum(), rose::stringifySgInitializedName_preinitialization_enum(), rose::stringifySgInterfaceStatement_generic_spec_enum(), rose::stringifySgIOStatement_io_statement_enum(), rose::stringifySgLabelSymbol_label_type_enum(), rose::stringifySgLinkageModifier_linkage_modifier_enum(), rose::stringifySgMemberFunctionType_mfunc_specifier_enum(), rose::stringifySgOmpClause_omp_default_option_enum(), rose::stringifySgOmpClause_omp_map_operator_enum(), rose::stringifySgOmpClause_omp_reduction_operator_enum(), rose::stringifySgOmpClause_omp_schedule_kind_enum(), rose::stringifySgOpenclAccessModeModifier_access_mode_modifier_enum(), rose::stringifySgProcedureHeaderStatement_subprogram_kind_enum(), rose::stringifySgProject_template_instantiation_enum(), rose::stringifySgSpecialFunctionModifier_special_function_modifier_enum(), rose::stringifySgStopOrPauseStatement_stop_or_pause_enum(), rose::stringifySgStorageModifier_storage_modifier_enum(), rose::stringifySgTemplateArgument_template_argument_enum(), rose::stringifySgTemplateClassDeclaration_class_types(), rose::stringifySgTemplateDeclaration_template_type_enum(), rose::stringifySgTemplateParameter_template_parameter_enum(), rose::stringifySgThrowOp_e_throw_kind(), rose::stringifySgTokenROSE_C_CXX_keywords(), rose::stringifySgTokenROSE_C_CXX_Operators(), rose::stringifySgTokenROSE_Fortran_Additional_Info(), rose::stringifySgTokenROSE_Fortran_Keywords(), rose::stringifySgTokenROSE_Fortran_Operators(), rose::stringifySgType_fortran_attribute_specifiers_enum(), rose::stringifySgTypeModifier_gnu_extension_machine_mode_enum(), rose::stringifySgTypeModifier_type_modifier_enum(), rose::stringifySgUnaryOpSgop_mode(), rose::stringifySgUnparse_Info_access_attr_enum(), rose::stringifySgUnparse_Info_unparse_type_num(), rose::stringifySgUPC_AccessModifier_upc_access_modifier_enum(), rose::stringifySgVariableDeclaration_gnu_extension_declaration_attributes_enum(), rose::stringifySMTSolverSatisfiable(), rose::stringifySnippetInsertMechanism(), rose::stringifySnippetLocalDeclarationPosition(), rose::stringifySqlDatabaseDriver(), rose::stringifyStringUtilityFileNameLocation(), rose::stringifyStringUtilityOSType(), rose::stringifyTaintLatticeVertex(), rose::stringifyTaskState(), rose::stringifyTerminal_includeExcludeMechanism(), rose::stringifyTerminal_locationInTree(), rose::stringifyTerminalTypeEvaluation(), rose::stringifyTransformationSupport_operatorCodeType(), rose::stringifyVariantT(), rose::stringifyVirtualBinCFG_EdgeConditionKind(), rose::stringifyVirtualCFG_EdgeConditionKind(), rose::stringifyX86BranchPrediction(), rose::stringifyX86Flag(), rose::stringifyX86GeneralPurposeRegister(), rose::stringifyX86InstructionKind(), rose::stringifyX86InstructionSize(), rose::stringifyX86RegisterClass(), rose::stringifyX86RepeatPrefix(), rose::stringifyX86SegmentRegister(), rose::stringifyYicesSolverLinkMode(), and unexpected_node().

template<class T >
T& sg::deref ( T *  ptr)

dereferences an object (= checked dereference in debug mode)

Definition at line 37 of file sageGeneric.h.

static void sg::unexpected_node ( const SgNode n)
inlinestatic

Definition at line 60 of file sageGeneric.h.

References name, and unused().

Referenced by _dispatch(), and sg::TypeRecoveryHandler< SageNode >::handle().

template<class SageNode >
static SageNode& sg::assume_sage_type ( SgNode n)
inlinestatic

unchecked down cast from SgNode to SageNode

Definition at line 103 of file sageGeneric.h.

template<class SageNode >
static const SageNode& sg::assume_sage_type ( const SgNode n)
inlinestatic

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Note
overloaded to preserve constness

Definition at line 112 of file sageGeneric.h.

template<class RoseVisitor , class SageNode >
static RoseVisitor sg::_dispatch ( RoseVisitor  rv,
SageNode *  n 
)
inlinestatic

for internal use (use dispatch instead)

Definition at line 147 of file sageGeneric.h.

References dispatch(), unexpected_node(), V_Sg_File_Info, V_SgAccessModifier, V_SgActualArgumentExpression, V_SgAddOp, V_SgAddressOfOp, V_SgAggregateInitializer, V_SgAliasSymbol, V_SgAllocateStatement, V_SgAndAssignOp, V_SgAndOp, V_SgArithmeticIfStatement, V_SgArrayType, V_SgArrowExp, V_SgArrowStarOp, V_SgAsmArmInstruction, V_SgAsmArmRegisterReferenceExpression, V_SgAsmBasicString, V_SgAsmBinaryAdd, V_SgAsmBinaryAddPostupdate, V_SgAsmBinaryAddPreupdate, V_SgAsmBinaryAddressSymbol, V_SgAsmBinaryAsr, V_SgAsmBinaryDataSymbol, V_SgAsmBinaryDivide, V_SgAsmBinaryExpression, V_SgAsmBinaryLsl, V_SgAsmBinaryLsr, V_SgAsmBinaryMod, V_SgAsmBinaryMultiply, V_SgAsmBinaryRor, V_SgAsmBinarySubtract, V_SgAsmBinarySubtractPostupdate, V_SgAsmBinarySubtractPreupdate, V_SgAsmBlock, V_SgAsmCoffStrtab, V_SgAsmCoffSymbol, V_SgAsmCoffSymbolList, V_SgAsmCoffSymbolTable, V_SgAsmCommonSubExpression, V_SgAsmControlFlagsExpression, V_SgAsmDOSExtendedHeader, V_SgAsmDOSFileHeader, V_SgAsmDoubleFloatValueExpression, V_SgAsmDwarfAccessDeclaration, V_SgAsmDwarfArrayType, V_SgAsmDwarfBaseType, V_SgAsmDwarfCatchBlock, V_SgAsmDwarfClassTemplate, V_SgAsmDwarfClassType, V_SgAsmDwarfCommonBlock, V_SgAsmDwarfCommonInclusion, V_SgAsmDwarfCompilationUnit, V_SgAsmDwarfCompilationUnitList, V_SgAsmDwarfCondition, V_SgAsmDwarfConstant, V_SgAsmDwarfConstruct, V_SgAsmDwarfConstructList, V_SgAsmDwarfConstType, V_SgAsmDwarfDwarfProcedure, V_SgAsmDwarfEntryPoint, V_SgAsmDwarfEnumerationType, V_SgAsmDwarfEnumerator, V_SgAsmDwarfFileType, V_SgAsmDwarfFormalParameter, V_SgAsmDwarfFormatLabel, V_SgAsmDwarfFriend, V_SgAsmDwarfFunctionTemplate, V_SgAsmDwarfImportedDeclaration, V_SgAsmDwarfImportedModule, V_SgAsmDwarfImportedUnit, V_SgAsmDwarfInformation, V_SgAsmDwarfInheritance, V_SgAsmDwarfInlinedSubroutine, V_SgAsmDwarfInterfaceType, V_SgAsmDwarfLabel, V_SgAsmDwarfLexicalBlock, V_SgAsmDwarfLine, V_SgAsmDwarfLineList, V_SgAsmDwarfMacro, V_SgAsmDwarfMacroList, V_SgAsmDwarfMember, V_SgAsmDwarfModule, V_SgAsmDwarfMutableType, V_SgAsmDwarfNamelist, V_SgAsmDwarfNamelistItem, V_SgAsmDwarfNamespace, V_SgAsmDwarfPackedType, V_SgAsmDwarfPartialUnit, V_SgAsmDwarfPointerType, V_SgAsmDwarfPtrToMemberType, V_SgAsmDwarfReferenceType, V_SgAsmDwarfRestrictType, V_SgAsmDwarfSetType, V_SgAsmDwarfSharedType, V_SgAsmDwarfStringType, V_SgAsmDwarfStructureType, V_SgAsmDwarfSubprogram, V_SgAsmDwarfSubrangeType, V_SgAsmDwarfSubroutineType, V_SgAsmDwarfTemplateTypeParameter, V_SgAsmDwarfTemplateValueParameter, V_SgAsmDwarfThrownType, V_SgAsmDwarfTryBlock, V_SgAsmDwarfTypedef, V_SgAsmDwarfUnionType, V_SgAsmDwarfUnknownConstruct, V_SgAsmDwarfUnspecifiedParameters, V_SgAsmDwarfUnspecifiedType, V_SgAsmDwarfUpcRelaxedType, V_SgAsmDwarfUpcSharedType, V_SgAsmDwarfUpcStrictType, V_SgAsmDwarfVariable, V_SgAsmDwarfVariant, V_SgAsmDwarfVariantPart, V_SgAsmDwarfVolatileType, V_SgAsmDwarfWithStmt, V_SgAsmElfDynamicEntry, V_SgAsmElfDynamicEntryList, V_SgAsmElfDynamicSection, V_SgAsmElfEHFrameEntryCI, V_SgAsmElfEHFrameEntryCIList, V_SgAsmElfEHFrameEntryFD, V_SgAsmElfEHFrameEntryFDList, V_SgAsmElfEHFrameSection, V_SgAsmElfFileHeader, V_SgAsmElfNoteEntry, V_SgAsmElfNoteEntryList, V_SgAsmElfNoteSection, V_SgAsmElfRelocEntry, V_SgAsmElfRelocEntryList, V_SgAsmElfRelocSection, V_SgAsmElfSection, V_SgAsmElfSectionTable, V_SgAsmElfSectionTableEntry, V_SgAsmElfSegmentTable, V_SgAsmElfSegmentTableEntry, V_SgAsmElfSegmentTableEntryList, V_SgAsmElfStringSection, V_SgAsmElfStrtab, V_SgAsmElfSymbol, V_SgAsmElfSymbolList, V_SgAsmElfSymbolSection, V_SgAsmElfSymverDefinedAux, V_SgAsmElfSymverDefinedAuxList, V_SgAsmElfSymverDefinedEntry, V_SgAsmElfSymverDefinedEntryList, V_SgAsmElfSymverDefinedSection, V_SgAsmElfSymverEntry, V_SgAsmElfSymverEntryList, V_SgAsmElfSymverNeededAux, V_SgAsmElfSymverNeededAuxList, V_SgAsmElfSymverNeededEntry, V_SgAsmElfSymverNeededEntryList, V_SgAsmElfSymverNeededSection, V_SgAsmElfSymverSection, V_SgAsmExecutableFileFormat, V_SgAsmExpression, V_SgAsmExprListExp, V_SgAsmGenericDLL, V_SgAsmGenericDLLList, V_SgAsmGenericFile, V_SgAsmGenericFileList, V_SgAsmGenericFormat, V_SgAsmGenericHeader, V_SgAsmGenericHeaderList, V_SgAsmGenericSection, V_SgAsmGenericSectionList, V_SgAsmGenericString, V_SgAsmGenericStrtab, V_SgAsmGenericSymbol, V_SgAsmGenericSymbolList, V_SgAsmInstruction, V_SgAsmIntegerValueExpression, V_SgAsmInterpretation, V_SgAsmInterpretationList, V_SgAsmLEEntryPoint, V_SgAsmLEEntryTable, V_SgAsmLEFileHeader, V_SgAsmLENameTable, V_SgAsmLEPageTable, V_SgAsmLEPageTableEntry, V_SgAsmLERelocTable, V_SgAsmLESection, V_SgAsmLESectionTable, V_SgAsmLESectionTableEntry, V_SgAsmMemoryReferenceExpression, V_SgAsmNEEntryPoint, V_SgAsmNEEntryTable, V_SgAsmNEFileHeader, V_SgAsmNEModuleTable, V_SgAsmNENameTable, V_SgAsmNERelocEntry, V_SgAsmNERelocTable, V_SgAsmNESection, V_SgAsmNESectionTable, V_SgAsmNESectionTableEntry, V_SgAsmNEStringTable, V_SgAsmNode, V_SgAsmOp, V_SgAsmOperandList, V_SgAsmPEExportDirectory, V_SgAsmPEExportEntry, V_SgAsmPEExportEntryList, V_SgAsmPEExportSection, V_SgAsmPEFileHeader, V_SgAsmPEImportDirectory, V_SgAsmPEImportDirectoryList, V_SgAsmPEImportItem, V_SgAsmPEImportItemList, V_SgAsmPEImportSection, V_SgAsmPERVASizePair, V_SgAsmPERVASizePairList, V_SgAsmPESection, V_SgAsmPESectionTable, V_SgAsmPESectionTableEntry, V_SgAsmPEStringSection, V_SgAsmPowerpcInstruction, V_SgAsmPowerpcRegisterReferenceExpression, V_SgAsmRegisterReferenceExpression, V_SgAsmSingleFloatValueExpression, V_SgAsmStatement, V_SgAsmStmt, V_SgAsmStoredString, V_SgAsmStringStorage, V_SgAsmType, V_SgAsmType128bitFloat, V_SgAsmType80bitFloat, V_SgAsmTypeByte, V_SgAsmTypeDoubleFloat, V_SgAsmTypeDoubleQuadWord, V_SgAsmTypeDoubleWord, V_SgAsmTypeQuadWord, V_SgAsmTypeSingleFloat, V_SgAsmTypeVector, V_SgAsmTypeWord, V_SgAsmUnaryArmSpecialRegisterList, V_SgAsmUnaryExpression, V_SgAsmUnaryMinus, V_SgAsmUnaryPlus, V_SgAsmUnaryRrx, V_SgAsmValueExpression, V_SgAsmx86Instruction, V_SgAsmx86RegisterReferenceExpression, V_SgAssignedGotoStatement, V_SgAssignInitializer, V_SgAssignOp, V_SgAssignStatement, V_SgAssociateStatement, V_SgAsteriskShapeExp, V_SgAttribute, V_SgAttributeSpecificationStatement, V_SgBackspaceStatement, V_SgBaseClass, V_SgBaseClassModifier, V_SgBasicBlock, V_SgBidirectionalGraph, V_SgBinaryComposite, V_SgBinaryOp, V_SgBitAndOp, V_SgBitAttribute, V_SgBitComplementOp, V_SgBitOrOp, V_SgBitXorOp, V_SgBlockDataStatement, V_SgBoolValExp, V_SgBreakStmt, V_SgC_PreprocessorDirectiveStatement, V_SgCAFCoExpression, V_SgCAFWithTeamStatement, V_SgCaseOptionStmt, V_SgCastExp, V_SgCatchOptionStmt, V_SgCatchStatementSeq, V_SgCharVal, V_SgClassDecl_attr, V_SgClassDeclaration, V_SgClassDefinition, V_SgClassNameRefExp, V_SgClassSymbol, V_SgClassType, V_SgClinkageDeclarationStatement, V_SgClinkageEndStatement, V_SgClinkageStartStatement, V_SgCloseStatement, V_SgColonShapeExp, V_SgCommaOpExp, V_SgCommonBlock, V_SgCommonBlockObject, V_SgCommonSymbol, V_SgComplexVal, V_SgComputedGotoStatement, V_SgConcatenationOp, V_SgConditionalExp, V_SgConjugateOp, V_SgConstructorInitializer, V_SgConstVolatileModifier, V_SgContainsStatement, V_SgContinueStmt, V_SgCtorInitializerList, V_SgCudaKernelCallExp, V_SgCudaKernelExecConfig, V_SgDataStatementGroup, V_SgDataStatementObject, V_SgDataStatementValue, V_SgDeadIfDirectiveStatement, V_SgDeallocateStatement, V_SgDeclarationModifier, V_SgDeclarationStatement, V_SgDefaultOptionStmt, V_SgDefaultSymbol, V_SgDefineDirectiveStatement, V_SgDeleteExp, V_SgDerivedTypeStatement, V_SgDesignatedInitializer, V_SgDimensionObject, V_SgDirectedGraphEdge, V_SgDirectory, V_SgDirectoryList, V_SgDivAssignOp, V_SgDivideOp, V_SgDotExp, V_SgDotStarOp, V_SgDoubleVal, V_SgDoWhileStmt, V_SgElaboratedTypeModifier, V_SgElseDirectiveStatement, V_SgElseifDirectiveStatement, V_SgElseWhereStatement, V_SgEmptyDirectiveStatement, V_SgEndfileStatement, V_SgEndifDirectiveStatement, V_SgEntryStatement, V_SgEnumDeclaration, V_SgEnumFieldSymbol, V_SgEnumSymbol, V_SgEnumType, V_SgEnumVal, V_SgEqualityOp, V_SgEquivalenceStatement, V_SgErrorDirectiveStatement, V_SgExponentiationOp, V_SgExpression, V_SgExpressionRoot, V_SgExprListExp, V_SgExprStatement, V_SgFile, V_SgFileList, V_SgFloatVal, V_SgFlushStatement, V_SgForAllStatement, V_SgForInitStatement, V_SgFormatItem, V_SgFormatItemList, V_SgFormatStatement, V_SgForStatement, V_SgFortranDo, V_SgFortranIncludeLine, V_SgFortranNonblockedDo, V_SgFuncDecl_attr, V_SgFunctionCallExp, V_SgFunctionDeclaration, V_SgFunctionDefinition, V_SgFunctionModifier, V_SgFunctionParameterList, V_SgFunctionParameterTypeList, V_SgFunctionRefExp, V_SgFunctionSymbol, V_SgFunctionType, V_SgFunctionTypeSymbol, V_SgFunctionTypeTable, V_SgGlobal, V_SgGotoStatement, V_SgGraph, V_SgGraphEdge, V_SgGraphEdgeList, V_SgGraphNode, V_SgGraphNodeList, V_SgGreaterOrEqualOp, V_SgGreaterThanOp, V_SgIdentDirectiveStatement, V_SgIfdefDirectiveStatement, V_SgIfDirectiveStatement, V_SgIfndefDirectiveStatement, V_SgIfStmt, V_SgImagPartOp, V_SgImplicitStatement, V_SgImpliedDo, V_SgImportStatement, V_SgIncidenceDirectedGraph, V_SgIncidenceUndirectedGraph, V_SgIncludeDirectiveStatement, V_SgIncludeNextDirectiveStatement, V_SgInitializedName, V_SgInitializer, V_SgInquireStatement, V_SgIntegerDivideOp, V_SgInterfaceBody, V_SgInterfaceStatement, V_SgInterfaceSymbol, V_SgIntKeyedBidirectionalGraph, V_SgIntrinsicSymbol, V_SgIntVal, V_SgIOItemExpression, V_SgIorAssignOp, V_SgIOStatement, V_SgLabelRefExp, V_SgLabelStatement, V_SgLabelSymbol, V_SgLessOrEqualOp, V_SgLessThanOp, V_SgLineDirectiveStatement, V_SgLinemarkerDirectiveStatement, V_SgLinkageModifier, V_SgLocatedNode, V_SgLocatedNodeSupport, V_SgLongDoubleVal, V_SgLongIntVal, V_SgLongLongIntVal, V_SgLshiftAssignOp, V_SgLshiftOp, V_SgMemberFunctionDeclaration, V_SgMemberFunctionRefExp, V_SgMemberFunctionSymbol, V_SgMemberFunctionType, V_SgMinusAssignOp, V_SgMinusMinusOp, V_SgMinusOp, V_SgModAssignOp, V_SgModifier, V_SgModifierNodes, V_SgModifierType, V_SgModOp, V_SgModuleStatement, V_SgModuleSymbol, V_SgMultAssignOp, V_SgMultiplyOp, V_SgName, V_SgNamedType, V_SgNameGroup, V_SgNamelistStatement, V_SgNamespaceAliasDeclarationStatement, V_SgNamespaceDeclarationStatement, V_SgNamespaceDefinitionStatement, V_SgNamespaceSymbol, V_SgNewExp, V_SgNode, V_SgNotEqualOp, V_SgNotOp, V_SgNullExpression, V_SgNullifyStatement, V_SgNullStatement, V_SgNumVariants, V_SgOmpAtomicStatement, V_SgOmpBarrierStatement, V_SgOmpBodyStatement, V_SgOmpClause, V_SgOmpClauseBodyStatement, V_SgOmpCollapseClause, V_SgOmpCopyinClause, V_SgOmpCopyprivateClause, V_SgOmpCriticalStatement, V_SgOmpDefaultClause, V_SgOmpDoStatement, V_SgOmpExpressionClause, V_SgOmpFirstprivateClause, V_SgOmpFlushStatement, V_SgOmpForStatement, V_SgOmpIfClause, V_SgOmpLastprivateClause, V_SgOmpMasterStatement, V_SgOmpNowaitClause, V_SgOmpNumThreadsClause, V_SgOmpOrderedClause, V_SgOmpOrderedStatement, V_SgOmpParallelStatement, V_SgOmpPrivateClause, V_SgOmpReductionClause, V_SgOmpScheduleClause, V_SgOmpSectionsStatement, V_SgOmpSectionStatement, V_SgOmpSharedClause, V_SgOmpSimdStatement, V_SgOmpSingleStatement, V_SgOmpTaskStatement, V_SgOmpTaskwaitStatement, V_SgOmpThreadprivateStatement, V_SgOmpUntiedClause, V_SgOmpVariablesClause, V_SgOmpWorkshareStatement, V_SgOpenclAccessModeModifier, V_SgOpenStatement, V_SgOptions, V_SgOrOp, V_SgParameterStatement, V_SgPartialFunctionModifierType, V_SgPartialFunctionType, V_SgPlusAssignOp, V_SgPlusPlusOp, V_SgPntrArrRefExp, V_SgPointerAssignOp, V_SgPointerDerefExp, V_SgPointerMemberType, V_SgPointerType, V_SgPragma, V_SgPragmaDeclaration, V_SgPrintStatement, V_SgProcedureHeaderStatement, V_SgProgramHeaderStatement, V_SgProject, V_SgPseudoDestructorRefExp, V_SgQualifiedName, V_SgQualifiedNameType, V_SgReadStatement, V_SgRealPartOp, V_SgReferenceType, V_SgRefExp, V_SgRenamePair, V_SgRenameSymbol, V_SgReturnStmt, V_SgRewindStatement, V_SgRshiftAssignOp, V_SgRshiftOp, V_SgScopeOp, V_SgScopeStatement, V_SgSequenceStatement, V_SgShortVal, V_SgSizeOfOp, V_SgSourceFile, V_SgSpawnStmt, V_SgSpecialFunctionModifier, V_SgStatement, V_SgStatementExpression, V_SgStatementFunctionStatement, V_SgStopOrPauseStatement, V_SgStorageModifier, V_SgStringKeyedBidirectionalGraph, V_SgStringVal, V_SgSubscriptExpression, V_SgSubtractOp, V_SgSupport, V_SgSwitchStatement, V_SgSymbol, V_SgSymbolTable, V_SgTemplateArgument, V_SgTemplateArgumentList, V_SgTemplateDeclaration, V_SgTemplateInstantiationDecl, V_SgTemplateInstantiationDefn, V_SgTemplateInstantiationDirectiveStatement, V_SgTemplateInstantiationFunctionDecl, V_SgTemplateInstantiationMemberFunctionDecl, V_SgTemplateParameter, V_SgTemplateParameterList, V_SgTemplateSymbol, V_SgTemplateType, V_SgThisExp, V_SgThrowOp, V_SgToken, V_SgTryStmt, V_SgType, V_SgTypeBool, V_SgTypeCAFTeam, V_SgTypeChar, V_SgTypeComplex, V_SgTypeCrayPointer, V_SgTypeDefault, V_SgTypedefDeclaration, V_SgTypedefSeq, V_SgTypedefSymbol, V_SgTypedefType, V_SgTypeDouble, V_SgTypeEllipse, V_SgTypeFloat, V_SgTypeGlobalVoid, V_SgTypeIdOp, V_SgTypeImaginary, V_SgTypeInt, V_SgTypeLong, V_SgTypeLongDouble, V_SgTypeLongLong, V_SgTypeModifier, V_SgTypeShort, V_SgTypeSignedChar, V_SgTypeSignedInt, V_SgTypeSignedLong, V_SgTypeSignedLongLong, V_SgTypeSignedShort, V_SgTypeString, V_SgTypeTable, V_SgTypeUnknown, V_SgTypeUnsignedChar, V_SgTypeUnsignedInt, V_SgTypeUnsignedLong, V_SgTypeUnsignedLongLong, V_SgTypeUnsignedShort, V_SgTypeVoid, V_SgTypeWchar, V_SgUnaryAddOp, V_SgUnaryOp, V_SgUndefDirectiveStatement, V_SgUndirectedGraphEdge, V_SgUnknownArrayOrFunctionReference, V_SgUnknownFile, V_SgUnparse_Info, V_SgUnsignedCharVal, V_SgUnsignedIntVal, V_SgUnsignedLongLongIntVal, V_SgUnsignedLongVal, V_SgUnsignedShortVal, V_SgUPC_AccessModifier, V_SgUpcBarrierStatement, V_SgUpcBlocksizeofExpression, V_SgUpcElemsizeofExpression, V_SgUpcFenceStatement, V_SgUpcForAllStatement, V_SgUpcLocalsizeofExpression, V_SgUpcMythread, V_SgUpcNotifyStatement, V_SgUpcThreads, V_SgUpcWaitStatement, V_SgUserDefinedBinaryOp, V_SgUserDefinedUnaryOp, V_SgUseStatement, V_SgUsingDeclarationStatement, V_SgUsingDirectiveStatement, V_SgValueExp, V_SgVarArgCopyOp, V_SgVarArgEndOp, V_SgVarArgOp, V_SgVarArgStartOneOperandOp, V_SgVarArgStartOp, V_SgVariableDeclaration, V_SgVariableDefinition, V_SgVariableSymbol, V_SgVariantExpression, V_SgVariantStatement, V_SgVarRefExp, V_SgWaitStatement, V_SgWarningDirectiveStatement, V_SgWcharVal, V_SgWhereStatement, V_SgWhileStmt, V_SgWriteStatement, and V_SgXorAssignOp.

Referenced by dispatch().

template<class RoseVisitor >
RoseVisitor sg::dispatch ( const RoseVisitor &  rv,
SgNode n 
)
inline

uncovers the type of SgNode and passes it to an overloaded function handle in RoseVisitor.

Template Parameters
RoseVisitorthe visitor that will be called back with the recovered type information. The handle function with the most suitable SgNode type will get invoked.
Parameters
rvan instance of a rose visitor; note that the argument is essentially passed by value (similar to STL's for_each).
na Sage node
Returns
a copy of the RoseVisitor object

The following code has two classes.

  • Counter counts the number of all expression and statement nodes. It implements handlers for SgNode (not interesting nodes), for SgExpression and SgStatement (to count the nodes).
  • Traversal inherits from ASTTraversal and contains a counter. The dispatch function is invoked using a Counter object and a pointer to an AST node. Since the counter object is passed by value we need to store back the result (similar to std::for_each).
    struct Counter
    {
    size_t expr;
    size_t decl;
    Counter() : expr(0), decl(0) {}
    void handle(const SgNode&) {}
    void handle(const SgExpression&) { ++expr; }
    void handle(const SgStatement&) { ++stmt; }
    };
    struct Traversal : ASTTraversal
    {
    Counter ctr;
    void visit(SgNode* n)
    {
    ctr = sg::dispatch(ctr, n);
    }
    void run(SgNode& root)
    {
    traverse(&root, preorder);
    std::cout << "Expr/Stmt ratio = " << ratio(ctr.expr, ctr.stmt) << std::endl;
    }
    static
    float ratio(float a, float b) { return a/b; }
    };
    Alternatively, the dispatch function takes a pointer to a handler object. In this case, the counter object is passed as pointer, and ctr is manipulated directly (no need to store back the result).
    void visit(SgNode* n)
    {
    sg::dispatch(&ctr, n);
    }

Definition at line 2790 of file sageGeneric.h.

References _dispatch().

Referenced by _ancestor(), _dispatch(), and assert_sage_type().

template<class RoseVisitor >
RoseVisitor sg::dispatch ( const RoseVisitor &  rv,
const SgNode n 
)
inline

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Definition at line 2799 of file sageGeneric.h.

References _dispatch().

template<class AncestorNode , class QualSgNode >
AncestorNode* sg::_ancestor ( QualSgNode &  n)

implements the ancestor search

see comments for AncestorTypeFinder

Definition at line 2842 of file sageGeneric.h.

References dispatch().

template<class AncestorNode >
AncestorNode* sg::ancestor ( SgNode n)

finds an ancestor node with a given type

the function family comes in four variants:

  • SgNode* -> AncestorNode* ( result can be NULL )
  • const SgNode* -> const AncestorNode* ( result can be NULL )
  • SgNode& -> AncestorNode& ( assert(false) when an ancestor of the specified type cannot be found )
  • const SgNode& -> const AncestorNode& ( assert(false) when an ancestor of the specified type cannot be found )
    const SgStatement* enclosingStatement(const SgExpression* e) { return sg::ancestor<SgStatement>(e); }

Definition at line 2868 of file sageGeneric.h.

Referenced by DominatorTreesAndDominanceFrontiers::TemplatedDominatorTree< CFGFilterFunction >::depthFirstSearch(), DominatorTreesAndDominanceFrontiers::TemplatedDominatorTree< CFGFilterFunction >::eval(), DominatorTreesAndDominanceFrontiers::TemplatedDominatorTree< CFGFilterFunction >::init(), and DominatorTreesAndDominanceFrontiers::TemplatedDominatorTree< CFGFilterFunction >::link().

template<class AncestorNode >
const AncestorNode* sg::ancestor ( const SgNode n)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Definition at line 2877 of file sageGeneric.h.

template<class AncestorNode >
AncestorNode& sg::ancestor ( SgNode n)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Definition at line 2886 of file sageGeneric.h.

template<class AncestorNode >
const AncestorNode& sg::ancestor ( const SgNode n)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Definition at line 2896 of file sageGeneric.h.

template<class SageNode >
SageNode* sg::assert_sage_type ( SgNode n)

asserts that n has type SageNode

the ROSE assert in the following example holds b/c assert_sage_type aborts if the input node is not a SgStatement

SgStatement* stmt = assert_sage_type<SgStatement>(expr.get_parent());
ROSE_ASSERT(stmt);

Definition at line 2929 of file sageGeneric.h.

References dispatch().

template<class SageNode >
const SageNode* sg::assert_sage_type ( const SgNode n)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Definition at line 2936 of file sageGeneric.h.

References dispatch().

static void sg::swap_parent ( SgNode lhs,
SgNode rhs 
)
inlinestatic

swaps the parent pointer of two nodes

Note
internal use

Definition at line 2944 of file sageGeneric.h.

References SgNode::get_parent(), and SgNode::set_parent().

Referenced by swap_child().

static void sg::swap_parent ( void *  ,
void *   
)
inlinestatic

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Note
for non sage nodes (nodes without a parent) e.g., Rose_Containers

Definition at line 2956 of file sageGeneric.h.

template<class SageNode , class SageChild >
void sg::swap_child ( SageNode &  lhs,
SageNode &  rhs,
SageChild *(SageNode::*)() const  getter,
void(SageNode::*)(SageChild *)  setter 
)

swaps children (of equal kind) between two ancestor nodes of the same type

Template Parameters
SageNodethe parent node type
SageChildthe child node type
Parameters
lhsone parent node
rhsanother parent node
getterthe getter function to extract the child from lhs (and rhs)
setterthe setter function to store the child in lhs (and rhs)

Definition at line 2966 of file sageGeneric.h.

References swap_parent().