[PATCH] D75286: [clangd] Handle clang-tidy suppression comments for diagnostics inside macro expansions
Nathan James via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Sat Mar 28 03:46:47 PDT 2020
njames93 added inline comments.
================
Comment at: clang-tools-extra/clang-tidy/ClangTidyDiagnosticConsumer.cpp:708-710
+ return std::tie(M1.FilePath, M1.FileOffset, LHS.DiagnosticName,
+ M1.Message) <
+ std::tie(M2.FilePath, M2.FileOffset, RHS.DiagnosticName, M2.Message);
----------------
This looks like a clang-format artifact, there are several other below. Could these be removed from this patch
================
Comment at: clang-tools-extra/clangd/unittests/DiagnosticsTests.cpp:64
-MATCHER_P(FixMessage, Message, "") {
- return arg.Message == Message;
-}
+MATCHER_P(FixMessage, Message, "") { return arg.Message == Message; }
----------------
ditto
================
Comment at: clang-tools-extra/clangd/unittests/DiagnosticsTests.cpp:264-265
+ // Verify that we don't have "[check-name]" suffix in the message.
+ WithFix(FixMessage(
+ "use a trailing return type for this function")))));
}
----------------
ditto
================
Comment at: clang-tools-extra/clangd/unittests/DiagnosticsTests.cpp:841-842
- EXPECT_THAT(TU.build().getDiagnostics(),
- ElementsAre(Diag(Test.range(), "use of undeclared identifier 'a'")));
+ EXPECT_THAT(
+ TU.build().getDiagnostics(),
+ ElementsAre(Diag(Test.range(), "use of undeclared identifier 'a'")));
----------------
ditto
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D75286/new/
https://reviews.llvm.org/D75286
More information about the cfe-commits
mailing list