[PATCH] D27383: Add a new clang-format style option ObjCBlockResetsIndent.
Sean Lu via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon Dec 5 11:59:40 PST 2016
yixiang added a comment.
Discover a case where my code breaks. When the block signature has a return type in it, the indent doesn't gets reset properly. I need to fix this.
// clang-format -style='{ObjCBlockResetsIndent: true}' test.m
[self callAsyncMethodWithParam:2
withCompletionHandler:id ^ (BOOL success) {
if (true) {
return nil;
} else {
return nil;
}
}];
Expected result
// clang-format -style='{ObjCBlockResetsIndent: true}' test.m
[self callAsyncMethodWithParam:2
withCompletionHandler:id ^ (BOOL success) {
if (true) {
return nil;
} else {
return nil;
}
}];
https://reviews.llvm.org/D27383
More information about the cfe-commits
mailing list