Re: About "[super dealloc];"
Re: About "[super dealloc];"
- Subject: Re: About "[super dealloc];"
- From: Graham Cox <email@hidden>
- Date: Mon, 1 Jun 2009 21:59:44 +1000
On 01/06/2009, at 9:52 PM, Bright wrote:
When should use the "[super dealloc];"? Could anyone list all of
case.
Whenever you have overridden -dealloc. Simple as that.
When do you override dealloc? When there are instance member variables
(ivars) that must be released when your object is deallocated. While
these will usually be also allocated at init time, there's no reason
that there should be exact symmetry, so looking for it as a "rule" is
misguided.
--Graham
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden