class MatchFinder::MatchCallback
Declaration
class MatchFinder::MatchCallback { /* full declaration omitted */ };
Description
Called when the Match registered for it was successfully found in the AST.
Declared at: clang/include/clang/ASTMatchers/ASTMatchFinder.h:91
Method Overview
- public virtual llvm::Optional<TraversalKind> getCheckTraversalKind() const
- public virtual llvm::StringRef getID() const
- public virtual void onEndOfTranslationUnit()
- public virtual void onStartOfTranslationUnit()
- public virtual void run(const clang::ast_matchers::MatchFinder::MatchResult & Result)
- public virtual ~MatchCallback()
Methods
¶virtual llvm::Optional<TraversalKind>
getCheckTraversalKind() const
virtual llvm::Optional<TraversalKind>
getCheckTraversalKind() const
Description
TraversalKind to use while matching and processing the result nodes. This API is temporary to facilitate third parties porting existing code to the default behavior of clang-tidy.
Declared at: clang/include/clang/ASTMatchers/ASTMatchFinder.h:118
¶virtual llvm::StringRef getID() const
virtual llvm::StringRef getID() const
Description
An id used to group the matchers. This id is used, for example, for the profiling output. It defaults to "<unknown>".
Declared at: clang/include/clang/ASTMatchers/ASTMatchFinder.h:112
¶virtual void onEndOfTranslationUnit()
virtual void onEndOfTranslationUnit()
Description
Called at the end of each translation unit. Optionally override to do per translation unit tasks.
Declared at: clang/include/clang/ASTMatchers/ASTMatchFinder.h:106
¶virtual void onStartOfTranslationUnit()
virtual void onStartOfTranslationUnit()
Description
Called at the start of each translation unit. Optionally override to do per translation unit tasks.
Declared at: clang/include/clang/ASTMatchers/ASTMatchFinder.h:101
¶virtual void run(
const clang::ast_matchers::MatchFinder::
MatchResult& Result)
virtual void run(
const clang::ast_matchers::MatchFinder::
MatchResult& Result)
Description
Called on every match by the \c MatchFinder.
Declared at: clang/include/clang/ASTMatchers/ASTMatchFinder.h:96
Parameters
- const clang::ast_matchers::MatchFinder:: MatchResult& Result
¶virtual ~MatchCallback()
virtual ~MatchCallback()
Declared at: clang/include/clang/ASTMatchers/ASTMatchFinder.h:93