[PATCH] D115345: [clangd] Suppress IncludeCleaner warnings for headers behind pragma keep

Kadir Cetinkaya via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Dec 8 08:33:13 PST 2021


kadircet accepted this revision.
kadircet added a comment.
This revision is now accepted and ready to land.

thanks, lgtm!



================
Comment at: clang-tools-extra/clangd/unittests/IncludeCleanerTests.cpp:414
+  auto &Includes = AST.getIncludeStructure();
+  EXPECT_THAT(getUnused(AST, translateToHeaderIDs(ReferencedFiles, Includes,
+                                                  AST.getSourceManager())),
----------------
nit: just `EXPECT_THAT(AST.getDiagnostics(), llvm::ValueIs(IsEmpty()))` ?


================
Comment at: clang-tools-extra/clangd/unittests/IncludeCleanerTests.cpp:416
+                                                  AST.getSourceManager())),
+              ::testing::IsEmpty());
+}
----------------
nit: we mostly make use of a using decl for `testing::` symbols in clangd unittests rather than qualifying at call sites. can you introduce a using decl for this one instead (and clean up the other occurrence)?


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D115345/new/

https://reviews.llvm.org/D115345



More information about the cfe-commits mailing list