summaryrefslogtreecommitdiff
path: root/clang-tools-extra/clangd/unittests/tweaks/ExpandAutoTypeTests.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'clang-tools-extra/clangd/unittests/tweaks/ExpandAutoTypeTests.cpp')
-rw-r--r--clang-tools-extra/clangd/unittests/tweaks/ExpandAutoTypeTests.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/clang-tools-extra/clangd/unittests/tweaks/ExpandAutoTypeTests.cpp b/clang-tools-extra/clangd/unittests/tweaks/ExpandAutoTypeTests.cpp
index 96574a67b5a4..6d9d4362be7a 100644
--- a/clang-tools-extra/clangd/unittests/tweaks/ExpandAutoTypeTests.cpp
+++ b/clang-tools-extra/clangd/unittests/tweaks/ExpandAutoTypeTests.cpp
@@ -71,7 +71,8 @@ TEST_F(ExpandAutoTypeTest, Test) {
apply("void ns::Func() { au^to x = new ns::Class::Nested{}; }"),
"void ns::Func() { ns::Class::Nested * x = new ns::Class::Nested{}; }");
- EXPECT_UNAVAILABLE("dec^ltype(au^to) x = 10;");
+ EXPECT_EQ(apply("dec^ltype(auto) x = 10;"), "int x = 10;");
+ EXPECT_EQ(apply("decltype(au^to) x = 10;"), "int x = 10;");
// expanding types in structured bindings is syntactically invalid.
EXPECT_UNAVAILABLE("const ^auto &[x,y] = (int[]){1,2};");