• 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: ARC vs Manual Reference Counting
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: ARC vs Manual Reference Counting


  • Subject: Re: ARC vs Manual Reference Counting
  • From: Greg Parker <email@hidden>
  • Date: Mon, 09 Sep 2013 16:02:02 -0700

On Sep 9, 2013, at 3:45 PM, Patrick Cusack <email@hidden> wrote:
> I appreciate everyone's replies. It was a question asked in complete humility. I agree that computers can do analysis much better than humans and that the less code you write, the less you have to debug, so ARC makes a lot of sense. My question really stemmed from Apple's WWDC lecture which appeared to justify the switch on the flimsiest of grounds, ie no longer having to be confused by [NSString stringWithFormat:] vs [NSString initWithString:] which is a pretty easy memory management rule.

That's not the only motivation, but it's an easy one to illustrate on a slide.

It may be a simple rule, but the static analyzer taught us that everybody gets it wrong at least sometimes.

Fortunately, the static analyzer also taught us that the Cocoa memory management rules were followed strictly enough in practice to allow them to be automated with only a handful of special cases. Thus, ARC.


--
Greg Parker     email@hidden     Runtime Wrangler



_______________________________________________

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: 
 >ARC vs Manual Reference Counting (From: email@hidden)
 >Re: ARC vs Manual Reference Counting (From: Patrick Cusack <email@hidden>)
 >Re: ARC vs Manual Reference Counting (From: Jens Alfke <email@hidden>)
 >Re: ARC vs Manual Reference Counting (From: Alex Kac <email@hidden>)
 >Re: ARC vs Manual Reference Counting (From: Kyle Sluder <email@hidden>)
 >Re: ARC vs Manual Reference Counting (From: Tom Davie <email@hidden>)
 >Re: ARC vs Manual Reference Counting (From: Alex Zavatone <email@hidden>)
 >Re: ARC vs Manual Reference Counting (From: Patrick Cusack <email@hidden>)

  • Prev by Date: Re: ARC vs Manual Reference Counting
  • Next by Date: Re: 30x faster JSON date parsing
  • Previous by thread: Re: ARC vs Manual Reference Counting
  • Next by thread: Re: ARC vs Manual Reference Counting
  • Index(es):
    • Date
    • Thread