Removing a NSNotificationCenter observer in iOS 5 ARC
问题 I have an iOS 5 ARC-based project, and am having difficulty about where I should be removing the observer for the NSNotificationCenter observations which I have registered within a UIViewController . Similar posts on SO have said this should be done in the -dealloc method. Even though this method is not required in ARC projects I have added it with the following code: - (void)dealloc { [[NSNotificationCenter defaultCenter] removeObserver:self]; } As a test, I open the UIViewController (within