// there is also an identifier before the ().
if (LeftOfParens && (LeftOfParens->Tok.getIdentifierInfo() == NULL ||
LeftOfParens->is(tok::kw_return)) &&
- LeftOfParens->Type != TT_TemplateCloser &&
- LeftOfParens->Type != TT_ObjCMethodExpr && Current.Next &&
- (Current.Next->is(tok::identifier)))
+ LeftOfParens->Type != TT_TemplateCloser && Current.Next &&
+ Current.Next->is(tok::identifier))
IsCast = true;
if (IsCast && !ParensAreEmpty)
Current.Type = TT_CastRParen;
verifyFormat("throw [self errorFor:a];");
verifyFormat("@throw [self errorFor:a];");
+ verifyFormat("[(id)foo bar:(id)baz quux:(id)snorf];");
+ verifyFormat("[(id)foo bar:(id) ? baz : quux];");
+ verifyFormat("4 > 4 ? (id)a : (id)baz;");
+
// This tests that the formatter doesn't break after "backing" but before ":",
// which would be at 80 columns.
verifyFormat(