This is now obvious as the pointer alignment behavior was changed.
Before (even with pointer alignment "Left"):
MACRO Constructor(const int &i) : a(a), b(b) {}
After:
MACRO Constructor(const int& i) : a(a), b(b) {}
llvm-svn: 235301
parseTemplateDeclaration();
break;
case tok::comma:
- if (Contexts.back().FirstStartOfName && Contexts.size() == 1) {
+ if (Contexts.back().InCtorInitializer)
+ Tok->Type = TT_CtorInitializerComma;
+ else if (Contexts.back().FirstStartOfName && Contexts.size() == 1) {
Contexts.back().FirstStartOfName->PartOfMultiVariableDeclStmt = true;
Line.IsMultiVariableDeclStmt = true;
}
- if (Contexts.back().InCtorInitializer)
- Tok->Type = TT_CtorInitializerComma;
if (Contexts.back().IsForEachMacro)
Contexts.back().IsExpression = true;
break;
verifyIndependentOfContext("int x = ~*p;");
verifyFormat("Constructor() : a(a), area(width * height) {}");
verifyFormat("Constructor() : a(a), area(a, width * height) {}");
+ verifyGoogleFormat("MACRO Constructor(const int& i) : a(a), b(b) {}");
verifyFormat("void f() { f(a, c * d); }");
verifyIndependentOfContext("InvalidRegions[*R] = 0;");