Skip to content

Instantly share code, notes, and snippets.

@christianroman
Last active January 1, 2016 08:19
Show Gist options
  • Save christianroman/8117111 to your computer and use it in GitHub Desktop.
Save christianroman/8117111 to your computer and use it in GitHub Desktop.
Objective-C trivia
typedef void (^AboutBlock)();
@interface MyController : UIViewController {
AboutBlock aboutBlock;
}
@end
#import "MyController.h"
@implementation MyController
- (void)viewDidLoad {
[super viewDidLoad];
aboutBlock = ^() {
NSLog(@"%@", [self description]);
};
aboutBlock();
}
@end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment