clang  12.0.0git
Classes | Functions | Variables
clang::ast_matchers::internal Namespace Reference

Classes

class  CollectMatchesCallback
 

Functions

bool NotUnaryOperator (const DynTypedNode &DynNode, ASTMatchFinder *Finder, BoundNodesTreeBuilder *Builder, ArrayRef< DynTypedMatcher > InnerMatchers)
 
bool AllOfVariadicOperator (const DynTypedNode &DynNode, ASTMatchFinder *Finder, BoundNodesTreeBuilder *Builder, ArrayRef< DynTypedMatcher > InnerMatchers)
 
bool EachOfVariadicOperator (const DynTypedNode &DynNode, ASTMatchFinder *Finder, BoundNodesTreeBuilder *Builder, ArrayRef< DynTypedMatcher > InnerMatchers)
 
bool AnyOfVariadicOperator (const DynTypedNode &DynNode, ASTMatchFinder *Finder, BoundNodesTreeBuilder *Builder, ArrayRef< DynTypedMatcher > InnerMatchers)
 
bool OptionallyVariadicOperator (const DynTypedNode &DynNode, ASTMatchFinder *Finder, BoundNodesTreeBuilder *Builder, ArrayRef< DynTypedMatcher > InnerMatchers)
 
bool matchesAnyBase (const CXXRecordDecl &Node, const Matcher< CXXBaseSpecifier > &BaseSpecMatcher, ASTMatchFinder *Finder, BoundNodesTreeBuilder *Builder)
 
static std::vector< std::string > vectorFromRefs (ArrayRef< const StringRef *> NameRefs)
 
Matcher< NamedDeclhasAnyNameFunc (ArrayRef< const StringRef *> NameRefs)
 
Matcher< ObjCMessageExprhasAnySelectorFunc (ArrayRef< const StringRef *> NameRefs)
 
HasOpNameMatcher hasAnyOperatorNameFunc (ArrayRef< const StringRef *> NameRefs)
 
HasOverloadOpNameMatcher hasAnyOverloadedOperatorNameFunc (ArrayRef< const StringRef *> NameRefs)
 
static bool consumeNameSuffix (StringRef &FullName, StringRef Suffix)
 
static StringRef getNodeName (const NamedDecl &Node, llvm::SmallString< 128 > &Scratch)
 
static StringRef getNodeName (const RecordDecl &Node, llvm::SmallString< 128 > &Scratch)
 
static StringRef getNodeName (const NamespaceDecl &Node, llvm::SmallString< 128 > &Scratch)
 
static bool isTokenAtLoc (const SourceManager &SM, const LangOptions &LangOpts, StringRef Text, SourceLocation Loc)
 
llvm::Optional< SourceLocationgetExpansionLocOfMacro (StringRef MacroName, SourceLocation Loc, const ASTContext &Context)
 
std::shared_ptr< llvm::Regex > createAndVerifyRegex (StringRef Regex, llvm::Regex::RegexFlags Flags, StringRef MatcherID)
 

Variables

static llvm::ManagedStatic< TrueMatcherImpl > TrueMatcherInstance
 

Function Documentation

◆ AllOfVariadicOperator()

bool clang::ast_matchers::internal::AllOfVariadicOperator ( const DynTypedNode DynNode,
ASTMatchFinder *  Finder,
BoundNodesTreeBuilder *  Builder,
ArrayRef< DynTypedMatcher >  InnerMatchers 
)

Definition at line 364 of file ASTMatchersInternal.cpp.

◆ AnyOfVariadicOperator()

bool clang::ast_matchers::internal::AnyOfVariadicOperator ( const DynTypedNode DynNode,
ASTMatchFinder *  Finder,
BoundNodesTreeBuilder *  Builder,
ArrayRef< DynTypedMatcher >  InnerMatchers 
)

Definition at line 391 of file ASTMatchersInternal.cpp.

◆ consumeNameSuffix()

static bool clang::ast_matchers::internal::consumeNameSuffix ( StringRef &  FullName,
StringRef  Suffix 
)
static

Definition at line 455 of file ASTMatchersInternal.cpp.

◆ createAndVerifyRegex()

std::shared_ptr<llvm::Regex> clang::ast_matchers::internal::createAndVerifyRegex ( StringRef  Regex,
llvm::Regex::RegexFlags  Flags,
StringRef  MatcherID 
)

Definition at line 687 of file ASTMatchersInternal.cpp.

◆ EachOfVariadicOperator()

bool clang::ast_matchers::internal::EachOfVariadicOperator ( const DynTypedNode DynNode,
ASTMatchFinder *  Finder,
BoundNodesTreeBuilder *  Builder,
ArrayRef< DynTypedMatcher >  InnerMatchers 
)

Definition at line 375 of file ASTMatchersInternal.cpp.

◆ getExpansionLocOfMacro()

llvm::Optional<SourceLocation> clang::ast_matchers::internal::getExpansionLocOfMacro ( StringRef  MacroName,
SourceLocation  Loc,
const ASTContext Context 
)

Definition at line 667 of file ASTMatchersInternal.cpp.

◆ getNodeName() [1/3]

static StringRef clang::ast_matchers::internal::getNodeName ( const NamedDecl Node,
llvm::SmallString< 128 > &  Scratch 
)
static

◆ getNodeName() [2/3]

static StringRef clang::ast_matchers::internal::getNodeName ( const RecordDecl Node,
llvm::SmallString< 128 > &  Scratch 
)
static

◆ getNodeName() [3/3]

static StringRef clang::ast_matchers::internal::getNodeName ( const NamespaceDecl Node,
llvm::SmallString< 128 > &  Scratch 
)
static

◆ hasAnyNameFunc()

Matcher<NamedDecl> clang::ast_matchers::internal::hasAnyNameFunc ( ArrayRef< const StringRef *>  NameRefs)

Definition at line 426 of file ASTMatchersInternal.cpp.

References vectorFromRefs().

◆ hasAnyOperatorNameFunc()

HasOpNameMatcher clang::ast_matchers::internal::hasAnyOperatorNameFunc ( ArrayRef< const StringRef *>  NameRefs)

Definition at line 436 of file ASTMatchersInternal.cpp.

References vectorFromRefs().

◆ hasAnyOverloadedOperatorNameFunc()

HasOverloadOpNameMatcher clang::ast_matchers::internal::hasAnyOverloadedOperatorNameFunc ( ArrayRef< const StringRef *>  NameRefs)

Definition at line 441 of file ASTMatchersInternal.cpp.

References vectorFromRefs().

◆ hasAnySelectorFunc()

Matcher<ObjCMessageExpr> clang::ast_matchers::internal::hasAnySelectorFunc ( ArrayRef< const StringRef *>  NameRefs)

Definition at line 431 of file ASTMatchersInternal.cpp.

References vectorFromRefs().

Referenced by clang::ast_matchers::AST_MATCHER_P().

◆ isTokenAtLoc()

static bool clang::ast_matchers::internal::isTokenAtLoc ( const SourceManager SM,
const LangOptions LangOpts,
StringRef  Text,
SourceLocation  Loc 
)
static

◆ matchesAnyBase()

bool clang::ast_matchers::internal::matchesAnyBase ( const CXXRecordDecl Node,
const Matcher< CXXBaseSpecifier > &  BaseSpecMatcher,
ASTMatchFinder *  Finder,
BoundNodesTreeBuilder *  Builder 
)

◆ NotUnaryOperator()

bool clang::ast_matchers::internal::NotUnaryOperator ( const DynTypedNode DynNode,
ASTMatchFinder *  Finder,
BoundNodesTreeBuilder *  Builder,
ArrayRef< DynTypedMatcher >  InnerMatchers 
)

Definition at line 344 of file ASTMatchersInternal.cpp.

◆ OptionallyVariadicOperator()

bool clang::ast_matchers::internal::OptionallyVariadicOperator ( const DynTypedNode DynNode,
ASTMatchFinder *  Finder,
BoundNodesTreeBuilder *  Builder,
ArrayRef< DynTypedMatcher >  InnerMatchers 
)

Definition at line 404 of file ASTMatchersInternal.cpp.

References clang::threadSafety::sx::matches().

◆ vectorFromRefs()

static std::vector<std::string> clang::ast_matchers::internal::vectorFromRefs ( ArrayRef< const StringRef *>  NameRefs)
inlinestatic

Variable Documentation

◆ TrueMatcherInstance

llvm::ManagedStatic<TrueMatcherImpl> clang::ast_matchers::internal::TrueMatcherInstance
static

Definition at line 192 of file ASTMatchersInternal.cpp.