summaryrefslogtreecommitdiffstats
path: root/clang/unittests/Format/FormatTest.cpp
diff options
context:
space:
mode:
authorDaniel Jasper <djasper@google.com>2015-06-12 07:15:33 +0000
committerDaniel Jasper <djasper@google.com>2015-06-12 07:15:33 +0000
commit554e49fe84c56a483b7eaeaf111716cfc4d0b6c0 (patch)
tree26b452fa8ca5319a7649e59d70caba3cf4f06771 /clang/unittests/Format/FormatTest.cpp
parent26ceb0845ba0fef388fd322ce71f5a96c19e7fc9 (diff)
downloadbcm5719-llvm-554e49fe84c56a483b7eaeaf111716cfc4d0b6c0.tar.gz
bcm5719-llvm-554e49fe84c56a483b7eaeaf111716cfc4d0b6c0.zip
clang-format: Understand C-style case in case label.
Before: case (my_int) ONE: After: case (my_int)ONE: This fixed llvm.org/PR23760 llvm-svn: 239597
Diffstat (limited to 'clang/unittests/Format/FormatTest.cpp')
-rw-r--r--clang/unittests/Format/FormatTest.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/clang/unittests/Format/FormatTest.cpp b/clang/unittests/Format/FormatTest.cpp
index 46be32bf4b1..e6df49d4590 100644
--- a/clang/unittests/Format/FormatTest.cpp
+++ b/clang/unittests/Format/FormatTest.cpp
@@ -5818,6 +5818,7 @@ TEST_F(FormatTest, FormatsCasts) {
verifyFormat("my_int a = (const my_int *)-1;");
verifyFormat("my_int a = (my_int)(my_int)-1;");
verifyFormat("my_int a = (ns::my_int)-2;");
+ verifyFormat("case (my_int)ONE:");
// FIXME: single value wrapped with paren will be treated as cast.
verifyFormat("void f(int i = (kValue)*kMask) {}");
OpenPOWER on IntegriCloud