summaryrefslogtreecommitdiffstats
path: root/clang/lib/Format
diff options
context:
space:
mode:
authorDaniel Jasper <djasper@google.com>2014-05-19 08:06:34 +0000
committerDaniel Jasper <djasper@google.com>2014-05-19 08:06:34 +0000
commit7f0c517168be0873856c54c0443da5341046e03e (patch)
tree48e79081322acacd8d939977a2b3fcad64a59068 /clang/lib/Format
parent0dd5291e698d03222365efec1d37da28ab91de22 (diff)
downloadbcm5719-llvm-7f0c517168be0873856c54c0443da5341046e03e.tar.gz
bcm5719-llvm-7f0c517168be0873856c54c0443da5341046e03e.zip
clang-format: Don't force line breaks in ObjC calls with ColumnLimit 0.
Before: [self.x a:b c:d]; Got reformatted toi (with ColumnLimit set to 0): [self.x a:b c:d]; llvm-svn: 209114
Diffstat (limited to 'clang/lib/Format')
-rw-r--r--clang/lib/Format/ContinuationIndenter.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/Format/ContinuationIndenter.cpp b/clang/lib/Format/ContinuationIndenter.cpp
index 77d981b8f5e..63bb5e9918b 100644
--- a/clang/lib/Format/ContinuationIndenter.cpp
+++ b/clang/lib/Format/ContinuationIndenter.cpp
@@ -739,7 +739,7 @@ unsigned ContinuationIndenter::moveStateToNextToken(LineState &State,
Current.PackingKind == PPK_Inconclusive)));
// If this '[' opens an ObjC call, determine whether all parameters fit
// into one line and put one per line if they don't.
- if (Current.Type == TT_ObjCMethodExpr &&
+ if (Current.Type == TT_ObjCMethodExpr && Style.ColumnLimit != 0 &&
getLengthToMatchingParen(Current) + State.Column >
getColumnLimit(State))
BreakBeforeParameter = true;
OpenPOWER on IntegriCloud