[PATCH] D93325: Add srcloc output to clang-query
Nathan James via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Fri Apr 23 08:35:13 PDT 2021
njames93 added inline comments.
================
Comment at: clang-tools-extra/clang-query/Query.cpp:106-108
+ if (Scout->first == CommonEntry) {
+ ++Iter;
+ }
----------------
nit: Elide braces.
================
Comment at: clang-tools-extra/clang-query/Query.cpp:122
+
+ TextDiagnostic TD(OS, Ctx.getLangOpts(), &Diags.getDiagnosticOptions());
+ TD.emitDiagnostic(FullSourceLoc(Iter->first, SM), DiagnosticsEngine::Note,
----------------
Can this be brought out the loop and re-used for each of the 3 loops?
================
Comment at: clang-tools-extra/clang-query/QueryParser.cpp:128
+ case OK_SrcLoc:
+ return new QueryType(&QuerySession::SrcLocOutput);
}
----------------
Can worry about detecting Introspection support in a follow-up
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D93325/new/
https://reviews.llvm.org/D93325
More information about the cfe-commits
mailing list