diff options
| -rw-r--r-- | clang/lib/Format/UnwrappedLineParser.cpp | 2 | ||||
| -rw-r--r-- | clang/unittests/Format/FormatTest.cpp | 1 |
2 files changed, 2 insertions, 1 deletions
diff --git a/clang/lib/Format/UnwrappedLineParser.cpp b/clang/lib/Format/UnwrappedLineParser.cpp index 293fd3c8bd1..ed28497ab99 100644 --- a/clang/lib/Format/UnwrappedLineParser.cpp +++ b/clang/lib/Format/UnwrappedLineParser.cpp @@ -354,7 +354,7 @@ void UnwrappedLineParser::calculateBraceTypes() { ProbablyBracedList = NextTok->isOneOf(tok::comma, tok::semi, tok::period, tok::colon, tok::r_paren, tok::r_square, tok::l_brace, - tok::l_paren) || + tok::l_paren, tok::ellipsis) || (NextTok->isBinaryOperator() && !NextIsObjCMethod); } if (ProbablyBracedList) { diff --git a/clang/unittests/Format/FormatTest.cpp b/clang/unittests/Format/FormatTest.cpp index b175d2a2ecb..8089b3e36ec 100644 --- a/clang/unittests/Format/FormatTest.cpp +++ b/clang/unittests/Format/FormatTest.cpp @@ -4580,6 +4580,7 @@ TEST_F(FormatTest, UnderstandsTemplateParameters) { " aaaaaaaaaaaaaaaaaaaaaaaaaaaaa >> aaaaa);", getLLVMStyleWithColumns(60)); verifyFormat("static_assert(is_convertible<A &&, B>::value, \"AAA\");"); + verifyFormat("Constructor(A... a) : a_(X<A>{std::forward<A>(a)}...) {}"); } TEST_F(FormatTest, UnderstandsBinaryOperators) { |

