[clang-tools-extra] 31dc248 - [clangd] Fix IncludeFixer test on windows
Sam McCall via cfe-commits
cfe-commits at lists.llvm.org
Wed Mar 23 10:57:15 PDT 2022
Author: Sam McCall
Date: 2022-03-23T18:57:08+01:00
New Revision: 31dc248ffc3cbf9ea6d11819b6b7b731b414b352
URL: https://github.com/llvm/llvm-project/commit/31dc248ffc3cbf9ea6d11819b6b7b731b414b352
DIFF: https://github.com/llvm/llvm-project/commit/31dc248ffc3cbf9ea6d11819b6b7b731b414b352.diff
LOG: [clangd] Fix IncludeFixer test on windows
Actual functionality doesn't seem to work with (default)
-fms-compatibility. Not sure why yet...
Added:
Modified:
clang-tools-extra/clangd/unittests/DiagnosticsTests.cpp
Removed:
################################################################################
diff --git a/clang-tools-extra/clangd/unittests/DiagnosticsTests.cpp b/clang-tools-extra/clangd/unittests/DiagnosticsTests.cpp
index f62b452353dcb..97e36dd828b21 100644
--- a/clang-tools-extra/clangd/unittests/DiagnosticsTests.cpp
+++ b/clang-tools-extra/clangd/unittests/DiagnosticsTests.cpp
@@ -1110,6 +1110,9 @@ ID(ns::X a6);
{SymbolWithHeader{"X", "unittest:///x.h", "\"x.h\""},
SymbolWithHeader{"ns::X", "unittest:///ns.h", "\"x.h\""}});
TU.ExternalIndex = Index.get();
+ // FIXME: -fms-compatibility (which is default on windows) breaks the
+ // ns::X cases when the namespace is undeclared. Find out why!
+ TU.ExtraArgs = {"-fno-ms-compatibility"};
EXPECT_THAT(*TU.build().getDiagnostics(), Each(withFix(_)));
}
More information about the cfe-commits
mailing list