Created
April 4, 2012 23:29
-
-
Save justin/2306549 to your computer and use it in GitHub Desktop.
Assert on initializers you aren't using
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- (id)initWithDocument:(ELDocument *)document | |
{ | |
if ((self = [super initWithNibName:nil bundle:nil])) | |
{ | |
// Do your stuff in here. | |
} | |
} | |
- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil | |
{ | |
NSAssert(NO, @"Use ELEditingViewController' initializer `initWithDocument:` instead"); | |
return nil; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment