When new class of UIViewController is added in Xcode, template does not include a dealloc method.
Now it is not a big deal 开发者_运维知识库to add one, obviously, but i wonder if there is a reason it is not included in a template?
I think Apple wants you to use:
- NIBs for UI components
- Autorelease blocks
- Automatic reference counting
All of the above techniques are taking care of the memory management process automatically. But it's just a suggested route. In Xcode 3.2 we had -dealloc
in UIViewController
template. And I use it often.
精彩评论