Custom dealloc and ARC (Objective-C) Custom dealloc and ARC (Objective-C) ios ios

Custom dealloc and ARC (Objective-C)


When using ARC, you simply do not call [super dealloc] explicitly - the compiler handles it for you (as described in the Clang LLVM ARC document, chapter 7.1.2):

- (void) dealloc{    [observer unregisterObject:self];    // [super dealloc]; //(provided by the compiler)}