aboutsummaryrefslogtreecommitdiff
path: root/lib/Format
diff options
context:
space:
mode:
authorDaniel Jasper <djasper@google.com>2013-05-06 06:45:09 +0000
committerDaniel Jasper <djasper@google.com>2013-05-06 06:45:09 +0000
commitc194c95036b7bf1281a6f2ed683f7c85ee5d2c20 (patch)
tree62afb62e0e21f88c1d45ed6f6622885207ad0bfc /lib/Format
parentf022018698ced7e538b338d4f7befef9f81051ea (diff)
Break the class-inheritance ":" to the new line.
This seems to be more common in LLVM, Google and Chromium. Before: class AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA : public BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB, public CCCCCCCCCCCCCCCCCCCCCCCCCCCCCC { }; After: class AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA : public BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB, public CCCCCCCCCCCCCCCCCCCCCCCCCCCCCC { }; git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@181183 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Format')
-rw-r--r--lib/Format/TokenAnnotator.cpp4
1 files changed, 1 insertions, 3 deletions
diff --git a/lib/Format/TokenAnnotator.cpp b/lib/Format/TokenAnnotator.cpp
index 10ced9a7ee..fa7ef78451 100644
--- a/lib/Format/TokenAnnotator.cpp
+++ b/lib/Format/TokenAnnotator.cpp
@@ -1137,11 +1137,9 @@ bool TokenAnnotator::canBreakBefore(const AnnotatedLine &Line,
if (Right.Type == TT_ConditionalExpr || Right.is(tok::question))
return true;
if (Right.Type == TT_RangeBasedForLoopColon ||
- Right.Type == TT_InheritanceColon ||
Right.Type == TT_OverloadedOperatorLParen)
return false;
- if (Left.Type == TT_RangeBasedForLoopColon ||
- Left.Type == TT_InheritanceColon)
+ if (Left.Type == TT_RangeBasedForLoopColon)
return true;
if (Right.Type == TT_RangeBasedForLoopColon)
return false;