Re: Release vs. autorelease
Re: Release vs. autorelease
- Subject: Re: Release vs. autorelease
- From: "I. Savant" <email@hidden>
- Date: Mon, 12 Jan 2009 16:50:32 -0500
On Mon, Jan 12, 2009 at 4:43 PM, Mohan Parthasarathy <email@hidden> wrote:
> I assumed that the reference count reached
> zero which is what you are hinting at i guess..
Bad assumption. :-) More precisely, a dangerous one. You've no idea
(because it's not your job to in a Cocoa program) what else may be
retaining this object. Relying on a retain count or expecting an
object to be deallocated when you release it will likely bite you some
day as this is not guaranteed (or terribly common, I believe).
--
I.S.
_______________________________________________
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