Created
May 24, 2014 22:29
-
-
Save rgregg/5cf07a3f1cbfa8dc6cdf to your computer and use it in GitHub Desktop.
Retain/Release Debugging
This file contains 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) retain | |
{ | |
NSLog(@"%@ retain: count: %d + 1", self, [self retainCount]); | |
return [super retain]; | |
} | |
- (void) release | |
{ | |
NSLog(@"%@ release: count: %d - 1", self, [self retainCount]); | |
[super release]; | |
} | |
- (void) dealloc | |
{ | |
NSLog(@"%@ dealloc: count: %d", self, [self retainCount]); | |
[super dealloc]; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment