• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Newbie: How to know whether an object is in autorelease pool
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Newbie: How to know whether an object is in autorelease pool


  • Subject: Re: Newbie: How to know whether an object is in autorelease pool
  • From: mmalc crawford <email@hidden>
  • Date: Tue, 11 Dec 2007 21:47:56 -0800


On Dec 11, 2007, at 9:38 PM, norio wrote:

I know that class factory puts its instance into autorelease pool.

Just to address this as a separate point: no, you don't.

An object you get back from a "convenience constructor" may typically be autoreleased, but there are some cases when it may not be (a shared singleton object, for example). To reiterate the point made in the previous reply; your only concern should be, do you own the object -- are you following the rules correctly.

mmalc

_______________________________________________

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


References: 
 >Newbie: How to know whether an object is in autorelease pool (From: norio <email@hidden>)

  • Prev by Date: Re: Newbie: How to know whether an object is in autorelease pool
  • Next by Date: Re: Key Value Observing?
  • Previous by thread: Re: Newbie: How to know whether an object is in autorelease pool
  • Next by thread: String parsing advice...
  • Index(es):
    • Date
    • Thread