• 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
Do I "own" objects returned to me by reference?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Do I "own" objects returned to me by reference?


  • Subject: Do I "own" objects returned to me by reference?
  • From: Jerry Krinock <email@hidden>
  • Date: Fri, 05 May 2006 18:57:16 -0700
  • Thread-topic: Do I "own" objects returned to me by reference?

For example, in NSScanner we have:

- (BOOL)scanString:(NSString *)string intoString:(NSString **)stringValue ;

Should I -release stringValue when I am done with it, or has it been
autoreleased?

Is there a memory-management convention for objects returned by reference
like this?

Jerry


 _______________________________________________
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

  • Follow-Ups:
    • Re: Do I "own" objects returned to me by reference?
      • From: Shawn Erickson <email@hidden>
  • Prev by Date: Re: Key-Value Coding Limitations
  • Next by Date: Cocoa-heads Lake Forest next week, 5/9, now with free stuff!
  • Previous by thread: Re: Bindings, a Tableview and an array (Newbie question)
  • Next by thread: Re: Do I "own" objects returned to me by reference?
  • Index(es):
    • Date
    • Thread