diff options
Diffstat (limited to 'clang/unittests/Format')
| -rw-r--r-- | clang/unittests/Format/FormatTest.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/clang/unittests/Format/FormatTest.cpp b/clang/unittests/Format/FormatTest.cpp index 433d0ec1d71..3b8f91130ff 100644 --- a/clang/unittests/Format/FormatTest.cpp +++ b/clang/unittests/Format/FormatTest.cpp @@ -866,6 +866,13 @@ TEST_F(FormatTest, CorrectlyHandlesLengthOfBlockComments) { getLLVMStyleWithColumns(40))); } +TEST_F(FormatTest, DontBreakNonTrailingBlockComments) { + EXPECT_EQ("void\n" + "ffffffffff(int aaaaa /* test */);", + format("void ffffffffff(int aaaaa /* test */);", + getLLVMStyleWithColumns(35))); +} + TEST_F(FormatTest, SplitsLongCxxComments) { EXPECT_EQ("// A comment that\n" "// doesn't fit on\n" |

