This is an archive of the discontinued LLVM Phabricator instance.

[clang-format] Improve ObjC method expressions formatting
AbandonedPublic

Authored by jolesiak on Jun 20 2018, 2:28 AM.

Details

Summary
  1. Fix counting parameters/arguments for ObjC.
  2. Fix split priorities for ObjC methods.
  3. Fix breaking after square bracket starting ObjC method expression.
  4. Fix putting ObjC method arguments into one line when they fit.

Test plan:

make -j12 FormatTests && tools/clang/unittests/Format/FormatTests

Diff Detail

Event Timeline

jolesiak created this revision.Jun 20 2018, 2:28 AM
jolesiak updated this revision to Diff 152043.Jun 20 2018, 2:48 AM
  • Add test
jolesiak edited the summary of this revision. (Show Details)Jun 20 2018, 2:52 AM
jolesiak added a reviewer: benhamilton.
benhamilton requested changes to this revision.Jun 27 2018, 9:37 AM

It's really hard to understand reviews which change 4 different things.

I hate to ask, but can you split this up into the 4 fixes?

This revision now requires changes to proceed.Jun 27 2018, 9:37 AM

It's really hard to understand reviews which change 4 different things.

I hate to ask, but can you split this up into the 4 fixes?

Sure, I'll split it tomorrow.