• 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: Memory management on returning nil in init
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Memory management on returning nil in init


  • Subject: Re: Memory management on returning nil in init
  • From: email@hidden
  • Date: Wed, 23 Jun 2010 15:47:49 -0400

On Jun 21, 2010, at 2:44 PM, Scott Anguish wrote:

> The old style
>
>> if (self = [super init])
>
> will cause a warnings with certain settings now and in the future.
>

Does this also apply to code such as:

    if (self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil])

should it be:

self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil];
if (self)

and any other initializers?

Thanks,
Dave



_______________________________________________

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

  • Follow-Ups:
    • Re: Memory management on returning nil in init
      • From: Jens Alfke <email@hidden>
References: 
 >Re: Memory management on returning nil in init (From: Matt Neuburg <email@hidden>)
 >Re: Memory management on returning nil in init (From: Scott Anguish <email@hidden>)
 >Re: Memory management on returning nil in init (From: Scott Anguish <email@hidden>)

  • Prev by Date: Re: changes to NSView's frame in its window
  • Next by Date: Re: Memory management on returning nil in init
  • Previous by thread: Re: Memory management on returning nil in init
  • Next by thread: Re: Memory management on returning nil in init
  • Index(es):
    • Date
    • Thread