summaryrefslogtreecommitdiffstats
path: root/clang/unittests/Format/FormatTest.cpp
diff options
context:
space:
mode:
authorDaniel Jasper <djasper@google.com>2013-12-02 09:19:27 +0000
committerDaniel Jasper <djasper@google.com>2013-12-02 09:19:27 +0000
commit0e81f1ad43e1bf87b70ac6500bd360b00db378fa (patch)
tree888225c12b239d44d3e23c3c075812cb49e3eb88 /clang/unittests/Format/FormatTest.cpp
parent08b9cf56be30b483f35c0401a8997473f456e025 (diff)
downloadbcm5719-llvm-0e81f1ad43e1bf87b70ac6500bd360b00db378fa.tar.gz
bcm5719-llvm-0e81f1ad43e1bf87b70ac6500bd360b00db378fa.zip
clang-format: Fix excessive formatting caused by r195954.
Due to a bug in the patch, clang-format would more or less simply format all multi-line comments. llvm-svn: 196080
Diffstat (limited to 'clang/unittests/Format/FormatTest.cpp')
-rw-r--r--clang/unittests/Format/FormatTest.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/clang/unittests/Format/FormatTest.cpp b/clang/unittests/Format/FormatTest.cpp
index 9fac17bc9e5..17972c62f8a 100644
--- a/clang/unittests/Format/FormatTest.cpp
+++ b/clang/unittests/Format/FormatTest.cpp
@@ -859,6 +859,13 @@ TEST_F(FormatTest, CanFormatCommentsLocally) {
"\n"
" // This is unrelated",
0, 0, getLLVMStyle()));
+ EXPECT_EQ("int a;\n"
+ "// This is\n"
+ "// not formatted. ",
+ format("int a;\n"
+ "// This is\n"
+ "// not formatted. ",
+ 0, 0, getLLVMStyle()));
}
TEST_F(FormatTest, RemovesTrailingWhitespaceOfComments) {
OpenPOWER on IntegriCloud