Re: [PATCH] D17700: [clang-format] Proposal for changes to Objective-C block formatting

2016-03-07 Thread Tony Arnold via cfe-commits
tonyarnold added a comment. > Blocks aren't the same as braces Yeah, good point. I guess I was just seeing the brace in the block, but that's the wrong way to think about it. http://reviews.llvm.org/D17700 ___ cfe-commits mailing list cfe-commits

Re: [PATCH] D17700: [clang-format] Proposal for changes to Objective-C block formatting

2016-02-28 Thread Tony Arnold via cfe-commits
tonyarnold added a comment. I did find one bug though — if there's any parameters in between the two blocks, they'll end up forcing a newline: objective-c @implementation SomeClass - (void)test { [sharedController passingTest:^BOOL(id application) { return appl

Re: [PATCH] D17700: [clang-format] Proposal for changes to Objective-C block formatting

2016-02-28 Thread Tony Arnold via cfe-commits
tonyarnold added a comment. Aside from the lack of tests, and `AllowNewlineBeforeBlockParameter` being outside of `BraceWrapping`, this is good! Much closer to how Apple's documentation and Xcode format blocks! 👍 Comment at: include/clang/Format/Format.h:421 @@ +420,3 @@ + //

Re: [PATCH] D9237: Update block formatting to behave like Xcode

2016-02-28 Thread Tony Arnold via cfe-commits
tonyarnold added a comment. @djasper so was the decision here to not merge these options? I think it's fair that you require a documented style guide somewhere (which Apple don't currently publish), however it would be good to at least have generic options in clang-format that allow us to repli