Re: Memory Management, A Working Example of My Question
Re: Memory Management, A Working Example of My Question
- Subject: Re: Memory Management, A Working Example of My Question
- From: Greg Herlihy <email@hidden>
- Date: Fri, 30 Dec 2005 20:42:21 -0500
It's not clear why this code needs an NSAutoreleasePool at all. Its use
appears to be almost entirely superfluous.
As long as a "part" is a member of an NSMutableArray (such as the goodParts
array or the replacementParts array) it will remain allocated. Once a part
is removed from every NSMutableArray that contains it, it becomes eligible
for deallocation and the runtime will reclaim its memory at some point. The
program need not be concerned with that detail.
Greg
On 12/30/05 7:43 PM, "Jordan Evans" <email@hidden> wrote:
>
Okay, I made a simple example that works. This I hope
>
will make it easier to understand my question.
>
>
Notice how in maintenance I release the pool, then
>
start it up again, so I could get around the dilemma I
>
described in my original question. My question: is
>
there a better way,
>
simpler way?
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden