[PATCH] D137677: [include-cleaner] add macro symbols and implicit refs to HTML report
Haojian Wu via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon Nov 14 02:59:08 PST 2022
hokein added a comment.
The new UI looks good.
================
Comment at: clang-tools-extra/include-cleaner/lib/Analysis.cpp:24
UsedSymbolCB CB) {
+ // This is duplicated in HTMLReport.cpp, changes should be mirrored there.
tooling::stdlib::Recognizer Recognizer;
----------------
nit: mention the `writeHTMLReport` function explicitly.
================
Comment at: clang-tools-extra/include-cleaner/lib/HTMLReport.cpp:355
+ walkAST(*Root, [&](SourceLocation Loc, const NamedDecl &D, RefType T) {
+ R.addRef(SymbolReference{Loc, D, T});
});
----------------
We need a special logic (`if (auto SS = Recognizer(&ND)) {...}`) for the stdlib symbols, otherwise, they will be treated as normal Decl symbols.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D137677/new/
https://reviews.llvm.org/D137677
More information about the cfe-commits
mailing list