aboutsummaryrefslogtreecommitdiff
path: root/lib/Format
diff options
context:
space:
mode:
authorDaniel Jasper <djasper@google.com>2013-04-05 17:21:59 +0000
committerDaniel Jasper <djasper@google.com>2013-04-05 17:21:59 +0000
commit27b91cc046f580fbe825f15b3e27f1b6407ee3e3 (patch)
treeefaea43690f511775f9bac2c02ed219767e21444 /lib/Format
parent3a163318526e7bfaa6012b411934728e2954047e (diff)
Fix bad formatting of overloaded operator definitions.
Before: bool operator< (const aaaaaaaaaaaaaaaaaaaaa &left, const aaaaaaaaaaaaaaaaaaaaa &right) { return left.group < right.group; } After: bool operator<(const aaaaaaaaaaaaaaaaaaaaa &left, const aaaaaaaaaaaaaaaaaaaaa &right) { return left.group < right.group; } git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@178887 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Format')
-rw-r--r--lib/Format/TokenAnnotator.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/Format/TokenAnnotator.cpp b/lib/Format/TokenAnnotator.cpp
index 427157e332..24e2b1f87e 100644
--- a/lib/Format/TokenAnnotator.cpp
+++ b/lib/Format/TokenAnnotator.cpp
@@ -1137,7 +1137,8 @@ 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_InheritanceColon ||
+ Right.Type == TT_OverloadedOperatorLParen)
return false;
if (Left.Type == TT_RangeBasedForLoopColon ||
Left.Type == TT_InheritanceColon)