clang: include/clang/Tooling/ASTDiff/ASTDiff.h Source File (original) (raw)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19#ifndef LLVM_CLANG_TOOLING_ASTDIFF_ASTDIFF_H
20#define LLVM_CLANG_TOOLING_ASTDIFF_ASTDIFF_H
21
23#include
24
26namespace diff {
27
34 UpdateMove
36
37
44
50};
51
52
53
55public:
56
58
59 template
64
67
73
76
77
79
80
81
82
85
88};
89
91
93
94
95
97
98
99
101
103
104
107 }
108};
109
111public:
114
115
117
119
120private:
121 std::unique_ptr DiffImpl;
122};
123
124}
125}
126
127#endif
Holds long-lived AST nodes (such as types and decls) that can be referred to throughout the semantic ...
constexpr bool isSame(ASTNodeKind Other) const
Returns true if this and Other represent the same kind.
NodeId getMapped(const SyntaxTree &SourceTree, NodeId Id) const
Represents the AST of a TranslationUnit.
SyntaxTree objects represent subtrees of the AST.
const Node & getNode(NodeId Id) const
StringRef getFilename() const
int findPositionInParent(NodeId Id) const
SyntaxTree(SyntaxTree &&Other)=default
const ASTContext & getASTContext() const
PreorderIterator begin() const
std::pair< unsigned, unsigned > getSourceRangeOffsets(const Node &N) const
std::unique_ptr< Impl > TreeImpl
SyntaxTree(T *Node, ASTContext &AST)
Constructs a tree from any AST node.
PreorderIterator end() const
std::string getNodeValue(NodeId Id) const
Serialize the node attributes to a string representation.
DynTypedNode DynTypedNode
The JSON file list parser is used to communicate input to InstallAPI.
const FunctionProtoType * T
@ Other
Other implicit parameter.
int MinHeight
During top-down matching, only consider nodes of at least this height.
double MinSimilarity
During bottom-up matching, match only nodes with at least this value as the ratio of their common des...
bool isMatchingAllowed(const Node &N1, const Node &N2) const
Returns false if the nodes should never be matched.
int MaxSize
Whenever two subtrees are matched in the bottom-up phase, the optimal mapping is computed,...
Within a tree, this identifies a node by its preorder offset.
Represents a Clang AST node, alongside some additional information.
NodeId RightMostDescendant
std::optional< std::string > getQualifiedIdentifier() const
std::optional< StringRef > getIdentifier() const
ASTNodeKind getType() const
NodeId LeftMostDescendant
StringRef getTypeLabel() const
SmallVector< NodeId, 4 > Children