clang 22.0.0git
DynamicRecursiveASTVisitor.cpp File Reference
#include "clang/AST/DynamicRecursiveASTVisitor.h"
#include "clang/AST/RecursiveASTVisitor.h"
#include "clang/AST/DeclNodes.inc"
#include "clang/AST/StmtNodes.inc"
#include "clang/AST/TypeNodes.inc"
#include "clang/AST/TypeLocNodes.def"

Go to the source code of this file.

Namespaces

namespace  clang
 The JSON file list parser is used to communicate input to InstallAPI.

Macros

#define DEF_TRAVERSE_TMPL_INST(kind)
#define ABSTRACT_DECL(DECL)
#define DECL(CLASS, BASE)
#define DECL(CLASS, BASE)
#define ABSTRACT_STMT(STMT)
#define STMT(CLASS, PARENT)
#define STMT(CLASS, PARENT)
#define ABSTRACT_TYPE(CLASS, BASE)
#define TYPE(CLASS, BASE)
#define TYPE(CLASS, BASE)
#define ABSTRACT_TYPELOC(CLASS, BASE)
#define TYPELOC(CLASS, BASE)
#define TYPELOC(CLASS, BASE)
#define FORWARD_TO_BASE(Function, Type, RefOrPointer)
#define FORWARD_TO_BASE_EXACT(Function, Type)
#define ABSTRACT_DECL(DECL)
#define DECL(CLASS, BASE)
#define ABSTRACT_STMT(STMT)
#define STMT(CLASS, PARENT)
#define STMT(CLASS, PARENT)
#define ABSTRACT_TYPE(CLASS, BASE)
#define TYPE(CLASS, BASE)
#define ABSTRACT_TYPELOC(CLASS, BASE)
#define TYPELOC(CLASS, BASE)
#define TYPELOC(CLASS, BASE)

Functions

 FORWARD_TO_BASE (TraverseConceptNestedRequirement, concepts::NestedRequirement, *) template< bool Const > bool DynamicRecursiveASTVisitorBase< Const >

Macro Definition Documentation

◆ ABSTRACT_DECL [1/2]

#define ABSTRACT_DECL ( DECL)

Definition at line 222 of file DynamicRecursiveASTVisitor.cpp.

◆ ABSTRACT_DECL [2/2]

#define ABSTRACT_DECL ( DECL)

Definition at line 222 of file DynamicRecursiveASTVisitor.cpp.

◆ ABSTRACT_STMT [1/2]

#define ABSTRACT_STMT ( STMT)

Definition at line 236 of file DynamicRecursiveASTVisitor.cpp.

◆ ABSTRACT_STMT [2/2]

#define ABSTRACT_STMT ( STMT)

Definition at line 236 of file DynamicRecursiveASTVisitor.cpp.

◆ ABSTRACT_TYPE [1/2]

#define ABSTRACT_TYPE ( CLASS,
BASE )

Definition at line 246 of file DynamicRecursiveASTVisitor.cpp.

◆ ABSTRACT_TYPE [2/2]

#define ABSTRACT_TYPE ( CLASS,
BASE )

Definition at line 246 of file DynamicRecursiveASTVisitor.cpp.

◆ ABSTRACT_TYPELOC [1/2]

#define ABSTRACT_TYPELOC ( CLASS,
BASE )

Definition at line 260 of file DynamicRecursiveASTVisitor.cpp.

◆ ABSTRACT_TYPELOC [2/2]

#define ABSTRACT_TYPELOC ( CLASS,
BASE )

Definition at line 260 of file DynamicRecursiveASTVisitor.cpp.

◆ DECL [1/3]

#define DECL ( CLASS,
BASE )
Value:
bool Traverse##CLASS##Decl(CLASS##Decl *D) { \
return Visitor.Traverse##CLASS##Decl(D); \
}
Decl - This represents one declaration (or definition), e.g.
Definition DeclBase.h:86

Definition at line 223 of file DynamicRecursiveASTVisitor.cpp.

◆ DECL [2/3]

#define DECL ( CLASS,
BASE )
Value:
bool Visit##CLASS##Decl(CLASS##Decl *D) { \
return Visitor.Visit##CLASS##Decl(D); \
}

Definition at line 223 of file DynamicRecursiveASTVisitor.cpp.

◆ DECL [3/3]

#define DECL ( CLASS,
BASE )
Value:
FORWARD_TO_BASE(Traverse##CLASS##Decl, CLASS##Decl, *) \
FORWARD_TO_BASE(WalkUpFrom##CLASS##Decl, CLASS##Decl, *)
#define FORWARD_TO_BASE(Function, Type, RefOrPointer)

Definition at line 223 of file DynamicRecursiveASTVisitor.cpp.

◆ DEF_TRAVERSE_TMPL_INST

#define DEF_TRAVERSE_TMPL_INST ( kind)
Value:
bool TraverseTemplateInstantiations(kind##TemplateDecl *D) { \
return Visitor.TraverseTemplateInstantiations(D); \
}
The base class of all kinds of template declarations (e.g., class, function, etc.).

Definition at line 212 of file DynamicRecursiveASTVisitor.cpp.

◆ FORWARD_TO_BASE

#define FORWARD_TO_BASE ( Function,
Type,
RefOrPointer )
Value:
template <bool Const> \
MaybeConst<Type> RefOrPointer Param) { \
return Impl<Const>(*this).RecursiveASTVisitor<Impl<Const>>::Function( \
const_cast<Type RefOrPointer>(Param)); \
}
Recursive AST visitor that supports extension via dynamic dispatch.
The base class of the type hierarchy.
Definition TypeBase.h:1833

Definition at line 283 of file DynamicRecursiveASTVisitor.cpp.

Referenced by FORWARD_TO_BASE().

◆ FORWARD_TO_BASE_EXACT

#define FORWARD_TO_BASE_EXACT ( Function,
Type )
Value:
template <bool Const> \
return Impl<Const>(*this).RecursiveASTVisitor<Impl<Const>>::Function( \
Param); \
}

Definition at line 292 of file DynamicRecursiveASTVisitor.cpp.

Referenced by FORWARD_TO_BASE().

◆ STMT [1/4]

#define STMT ( CLASS,
PARENT )
Value:
bool Traverse##CLASS(CLASS *S) { return Visitor.Traverse##CLASS(S); }

Definition at line 237 of file DynamicRecursiveASTVisitor.cpp.

◆ STMT [2/4]

#define STMT ( CLASS,
PARENT )
Value:
bool Visit##CLASS(CLASS *S) { return Visitor.Visit##CLASS(S); }

Definition at line 237 of file DynamicRecursiveASTVisitor.cpp.

◆ STMT [3/4]

#define STMT ( CLASS,
PARENT )
Value:
FORWARD_TO_BASE(Traverse##CLASS, CLASS, *)

Definition at line 237 of file DynamicRecursiveASTVisitor.cpp.

◆ STMT [4/4]

#define STMT ( CLASS,
PARENT )
Value:
FORWARD_TO_BASE(WalkUpFrom##CLASS, CLASS, *)

Definition at line 237 of file DynamicRecursiveASTVisitor.cpp.

◆ TYPE [1/3]

#define TYPE ( CLASS,
BASE )
Value:
bool Traverse##CLASS##Type(CLASS##Type *T, bool TraverseQualifier) { \
return Visitor.Traverse##CLASS##Type(T, TraverseQualifier); \
}
const FunctionProtoType * T
@ Type
The name was classified as a type.
Definition Sema.h:562

Definition at line 247 of file DynamicRecursiveASTVisitor.cpp.

◆ TYPE [2/3]

#define TYPE ( CLASS,
BASE )
Value:
bool Visit##CLASS##Type(CLASS##Type *T) { \
return Visitor.Visit##CLASS##Type(T); \
}

Definition at line 247 of file DynamicRecursiveASTVisitor.cpp.

◆ TYPE [3/3]

#define TYPE ( CLASS,
BASE )
Value:
template <bool Const> \
MaybeConst<CLASS##Type> *T, bool TraverseQualifier) { \
return Impl<Const>(*this) \
.RecursiveASTVisitor<Impl<Const>>::Traverse##CLASS##Type( \
const_cast<CLASS##Type *>(T), TraverseQualifier); \
} \
FORWARD_TO_BASE(WalkUpFrom##CLASS##Type, CLASS##Type, *)

Definition at line 247 of file DynamicRecursiveASTVisitor.cpp.

◆ TYPELOC [1/4]

#define TYPELOC ( CLASS,
BASE )
Value:
bool Traverse##CLASS##TypeLoc(CLASS##TypeLoc TL, bool TraverseQualifier) { \
return Visitor.Traverse##CLASS##TypeLoc(TL, TraverseQualifier); \
}
Base wrapper for a particular "section" of type source info.
Definition TypeLoc.h:59

Definition at line 261 of file DynamicRecursiveASTVisitor.cpp.

◆ TYPELOC [2/4]

#define TYPELOC ( CLASS,
BASE )
Value:
bool Visit##CLASS##TypeLoc(CLASS##TypeLoc TL) { \
return Visitor.Visit##CLASS##TypeLoc(TL); \
}

Definition at line 261 of file DynamicRecursiveASTVisitor.cpp.

◆ TYPELOC [3/4]

#define TYPELOC ( CLASS,
BASE )
Value:
template <bool Const> \
CLASS##TypeLoc TL, bool TraverseQualifier) { \
return Impl<Const>(*this) \
.RecursiveASTVisitor<Impl<Const>>::Traverse##CLASS##TypeLoc( \
TL, TraverseQualifier); \
}

Definition at line 261 of file DynamicRecursiveASTVisitor.cpp.

◆ TYPELOC [4/4]

#define TYPELOC ( CLASS,
BASE )
Value:
FORWARD_TO_BASE_EXACT(WalkUpFrom##CLASS##TypeLoc, CLASS##TypeLoc)
#define FORWARD_TO_BASE_EXACT(Function, Type)

Definition at line 261 of file DynamicRecursiveASTVisitor.cpp.

Function Documentation

◆ FORWARD_TO_BASE()

FORWARD_TO_BASE ( TraverseConceptNestedRequirement ,
concepts::NestedRequirement ,
*  )

Definition at line 311 of file DynamicRecursiveASTVisitor.cpp.

References FORWARD_TO_BASE, FORWARD_TO_BASE_EXACT, and clang::T.