class BoundNodesTreeBuilder
Declaration
class BoundNodesTreeBuilder { /* full declaration omitted */ };
Description
Creates BoundNodesTree objects. The tree builder is used during the matching process to insert the bound nodes from the Id matcher.
Declared at: clang/include/clang/ASTMatchers/ASTMatchersInternal.h:280
Member Variables
- private SmallVector< clang::ast_matchers::internal::BoundNodesMap, 1> Bindings
Method Overview
- public void addMatch(const clang::ast_matchers::internal::BoundNodesTreeBuilder & Bindings)
- public bool isComparable() const
- public template <typename ExcludePredicate>bool removeBindings(const ExcludePredicate & Predicate)
- public void setBinding(llvm::StringRef Id, const clang::DynTypedNode & DynNode)
- public void visitMatches(clang::ast_matchers::internal::BoundNodesTreeBuilder::Visitor * ResultVisitor)
Methods
¶void addMatch(
const clang::ast_matchers::internal::
BoundNodesTreeBuilder& Bindings)
void addMatch(
const clang::ast_matchers::internal::
BoundNodesTreeBuilder& Bindings)
Description
Adds a branch in the tree.
Declared at: clang/include/clang/ASTMatchers/ASTMatchersInternal.h:303
Parameters
- const clang::ast_matchers::internal:: BoundNodesTreeBuilder& Bindings
¶bool isComparable() const
bool isComparable() const
Description
Returns \c true if this \c BoundNodesTreeBuilder can be compared, i.e. all stored node maps have memoization data.
Declared at: clang/include/clang/ASTMatchers/ASTMatchersInternal.h:323
¶template <typename ExcludePredicate>
bool removeBindings(
const ExcludePredicate& Predicate)
template <typename ExcludePredicate>
bool removeBindings(
const ExcludePredicate& Predicate)
Declared at: clang/include/clang/ASTMatchers/ASTMatchersInternal.h:311
Templates
- ExcludePredicate
Parameters
- const ExcludePredicate& Predicate
¶void setBinding(
llvm::StringRef Id,
const clang::DynTypedNode& DynNode)
void setBinding(
llvm::StringRef Id,
const clang::DynTypedNode& DynNode)
Description
Add a binding from an id to a node.
Declared at: clang/include/clang/ASTMatchers/ASTMatchersInternal.h:295
Parameters
- llvm::StringRef Id
- const clang::DynTypedNode& DynNode
¶void visitMatches(
clang::ast_matchers::internal::
BoundNodesTreeBuilder::Visitor*
ResultVisitor)
void visitMatches(
clang::ast_matchers::internal::
BoundNodesTreeBuilder::Visitor*
ResultVisitor)
Description
Visits all matches that this BoundNodesTree represents. The ownership of 'ResultVisitor' remains at the caller.
Declared at: clang/include/clang/ASTMatchers/ASTMatchersInternal.h:308
Parameters
- clang::ast_matchers::internal:: BoundNodesTreeBuilder::Visitor* ResultVisitor