Ignore macros and implicit AST nodes, as well as anything outside of the
main source file.
Details
Details
Diff Detail
Diff Detail
- Repository
- rL LLVM
Event Timeline
Comment Actions
Just as a general note: adding cfe-commits after the fact is usually not a good idea, as we lose the history of the review in the email list (which is the source of truth).
Comment Actions
implicit nodes are noisy / they generally don't add information; I guess one could also keep them.
I excluded nodes outside of the main file are because the visualisation only works with single files for now.
That will change, same as with macros.
lib/Tooling/ASTDiff/ASTDiff.cpp | ||
---|---|---|
177 ↗ | (On Diff #109423) | You should just use one call isNodeExcluded that will redirect to node-specific overload, and avoid the multiple clauses in conditions, i.e..: static bool isSpecializedNodeExcluded(const Decl *D) { } static bool isSpecializedNodeExcluded(const Stmt *S) {} template <class T> static bool isNodeExcluded(const SourceManager &SrcMgr, T *N) { .... current code ... return isSpecializedNodeExcluded(N); } Then you can use if (isNodeExcluded(Tree.AST.getSourceManager(), D)) everywhere. |
test/Tooling/clang-diff-ast.cpp | ||
---|---|---|
68 ↗ | (On Diff #110555) |
|
test/Tooling/clang-diff-ast.cpp | ||
---|---|---|
68 ↗ | (On Diff #110555) | I want to assert that there is no output here, because other files are excluded, there may be a better way.. |