diff options
author | Daniel Jasper <djasper@google.com> | 2013-04-05 17:22:09 +0000 |
---|---|---|
committer | Daniel Jasper <djasper@google.com> | 2013-04-05 17:22:09 +0000 |
commit | 6b119d63f5036344acd4e00a6ff2b3c72f26966f (patch) | |
tree | 8b598309a67d06ab6cf016966d7fcce1c60967f3 /unittests | |
parent | 27b91cc046f580fbe825f15b3e27f1b6407ee3e3 (diff) |
Allow breaking after 'class' for classes with looong names.
(Don't ask, this was a user request).
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@178888 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'unittests')
-rw-r--r-- | unittests/Format/FormatTest.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/unittests/Format/FormatTest.cpp b/unittests/Format/FormatTest.cpp index 54e7381207..0ef241e34e 100644 --- a/unittests/Format/FormatTest.cpp +++ b/unittests/Format/FormatTest.cpp @@ -987,7 +987,7 @@ TEST_F(FormatTest, SeparatesLogicalBlocks) { "};")); } -TEST_F(FormatTest, FormatsDerivedClass) { +TEST_F(FormatTest, FormatsClasses) { verifyFormat("class A : public B {\n};"); verifyFormat("class A : public ::B {\n};"); @@ -1009,6 +1009,10 @@ TEST_F(FormatTest, FormatsDerivedClass) { " public F,\n" " public G {\n" "};"); + + verifyFormat("class\n" + " ReallyReallyLongClassName {\n};", + getLLVMStyleWithColumns(32)); } TEST_F(FormatTest, FormatsVariableDeclarationsAfterStructOrClass) { |