summaryrefslogtreecommitdiff
path: root/unittests/Format
diff options
context:
space:
mode:
authorDaniel Jasper <djasper@google.com>2014-06-11 07:35:16 +0000
committerDaniel Jasper <djasper@google.com>2014-06-11 07:35:16 +0000
commitc9ec1c267c72ecb1ef787bde6d420b20742fcdfc (patch)
tree82f02e35224a2ca0210c7933b4d7abae4c0099f6 /unittests/Format
parent6e4e00386eee93c4f226d9d07fd9169c3ef55ba3 (diff)
downloadclang-c9ec1c267c72ecb1ef787bde6d420b20742fcdfc.tar.gz
clang-c9ec1c267c72ecb1ef787bde6d420b20742fcdfc.tar.bz2
clang-c9ec1c267c72ecb1ef787bde6d420b20742fcdfc.tar.xz
clang-format: Fix pointer/reference detection after decltype.
Before: [](const decltype(*a) & value) {} After: [](const decltype(*a)& value) {} git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@210643 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'unittests/Format')
-rw-r--r--unittests/Format/FormatTest.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/unittests/Format/FormatTest.cpp b/unittests/Format/FormatTest.cpp
index a923e1a9f8..f474c42144 100644
--- a/unittests/Format/FormatTest.cpp
+++ b/unittests/Format/FormatTest.cpp
@@ -4740,6 +4740,7 @@ TEST_F(FormatTest, UnderstandsUsesOfStarAndAmp) {
verifyFormat("auto a = [](int **&, int ***) {};");
verifyFormat("auto PointerBinding = [](const char *S) {};");
verifyFormat("typedef typeof(int(int, int)) *MyFunc;");
+ verifyFormat("[](const decltype(*a) &value) {}");
verifyIndependentOfContext("typedef void (*f)(int *a);");
verifyIndependentOfContext("int i{a * b};");
verifyIndependentOfContext("aaa && aaa->f();");