Index: cfe/trunk/lib/Format/FormatToken.h =================================================================== --- cfe/trunk/lib/Format/FormatToken.h +++ cfe/trunk/lib/Format/FormatToken.h @@ -478,6 +478,7 @@ if (is(TT_TemplateString) && opensScope()) return true; return is(TT_ArrayInitializerLSquare) || + is(TT_ProtoExtensionLSquare) || (is(tok::l_brace) && (BlockKind == BK_Block || is(TT_DictLiteral) || (!Style.Cpp11BracedListStyle && NestingLevel == 0))) || Index: cfe/trunk/unittests/Format/FormatTestTextProto.cpp =================================================================== --- cfe/trunk/unittests/Format/FormatTestTextProto.cpp +++ cfe/trunk/unittests/Format/FormatTestTextProto.cpp @@ -389,6 +389,14 @@ " keyyyyyyyyyyyyyy: valuuuuuuuuuuuuuuuuuuuuuuuuue\n" " }\n" "}"); + verifyFormat( + "aaaaaaaaaaaaaaa {\n" + " bbbbbb {\n" + " [a.b/cy] {\n" + " eeeeeeeeeeeee: \"The lazy coo cat jumps over the lazy hot dog\"\n" + " }\n" + " }\n" + "}"); } TEST_F(FormatTestTextProto, NoSpaceAfterPercent) {