square / spacecommander

Commit fully-formatted Objective-C as a team without even trying.
Other
1.13k stars 177 forks source link

Combination Anonymous Function declaration/call is broken up #53

Open alanf opened 8 years ago

alanf commented 8 years ago
 UIViewController *const modalToDismiss = ^UIViewController *{
            switch (container.presentationStyle) {
                case MQCardOnFileLinkingFlowViewPresentationStyleModal:
                    return self.currentModalViewController;

                case MQCardOnFileLinkingFlowViewPresentationStyleFullScreen:
                    return (self.currentModalViewController != self.fullScreenNavigationController) ? self.fullScreenNavigationController : nil;
            }
}();

becomes

 UIViewController *const modalToDismiss = ^UIViewController *
        {
            switch (container.presentationStyle) {
                case MQCardOnFileLinkingFlowViewPresentationStyleModal:
                    return self.currentModalViewController;

                case MQCardOnFileLinkingFlowViewPresentationStyleFullScreen:
                    return (self.currentModalViewController != self.fullScreenNavigationController) ? self.fullScreenNavigationController : nil;
            }
        }
        ();