Skip to content

Commit

Permalink
[clangd] Fix Windows test failure by adding -fno-delayed-template-par…
Browse files Browse the repository at this point in the history
…sing to LocateSymbol.Ambiguous

Subscribers: ilya-biryukov, MaskRay, jkorous, arphaman, kadircet, usaxena95, cfe-commits

Tags: #clang

Differential Revision: https://reviews.llvm.org/D71444
  • Loading branch information
HighCommander4 committed Dec 13, 2019
1 parent b71475f commit 4f732a3
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion clang-tools-extra/clangd/unittests/XRefsTests.cpp
Expand Up @@ -586,7 +586,11 @@ TEST(LocateSymbol, Ambiguous) {
S<T>::ba$13^z(u);
}
)cpp");
auto AST = TestTU::withCode(T.code()).build();
auto TU = TestTU::withCode(T.code());
// FIXME: Go-to-definition in a template requires disabling delayed template
// parsing.
TU.ExtraArgs.push_back("-fno-delayed-template-parsing");
auto AST = TU.build();
// Ordered assertions are deliberate: we expect a predictable order.
EXPECT_THAT(locateSymbolAt(AST, T.point("1")), ElementsAre(Sym("str")));
EXPECT_THAT(locateSymbolAt(AST, T.point("2")), ElementsAre(Sym("str")));
Expand Down

0 comments on commit 4f732a3

Please sign in to comment.