summaryrefslogtreecommitdiffstats
path: root/clang/lib
diff options
context:
space:
mode:
authorKrasimir Georgiev <krasimir@google.com>2018-03-07 21:30:38 +0000
committerKrasimir Georgiev <krasimir@google.com>2018-03-07 21:30:38 +0000
commit9ad7af64232488ec7c8b4801486051ccdceeead2 (patch)
treeb5efd4823863c4f973b97f025d092ef9cb9589f3 /clang/lib
parentd8139348fbd485392dae2720015c491260c21767 (diff)
downloadbcm5719-llvm-9ad7af64232488ec7c8b4801486051ccdceeead2.tar.gz
bcm5719-llvm-9ad7af64232488ec7c8b4801486051ccdceeead2.zip
[clang-format] Break consecutive string literals in text protos
Summary: This patch fixes a bug where consecutive string literals in text protos were put on the same line. Reviewers: alexfh Reviewed By: alexfh Subscribers: klimek, cfe-commits Differential Revision: https://reviews.llvm.org/D44204 llvm-svn: 326945
Diffstat (limited to 'clang/lib')
-rw-r--r--clang/lib/Format/TokenAnnotator.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/clang/lib/Format/TokenAnnotator.cpp b/clang/lib/Format/TokenAnnotator.cpp
index 013a77b4c59..97a201d267e 100644
--- a/clang/lib/Format/TokenAnnotator.cpp
+++ b/clang/lib/Format/TokenAnnotator.cpp
@@ -2717,7 +2717,8 @@ bool TokenAnnotator::mustBreakBefore(const AnnotatedLine &Line,
return true;
} else if (Style.Language == FormatStyle::LK_Cpp ||
Style.Language == FormatStyle::LK_ObjC ||
- Style.Language == FormatStyle::LK_Proto) {
+ Style.Language == FormatStyle::LK_Proto ||
+ Style.Language == FormatStyle::LK_TextProto) {
if (Left.isStringLiteral() && Right.isStringLiteral())
return true;
}
OpenPOWER on IntegriCloud