Re: Static analyser grumbling
Re: Static analyser grumbling
- Subject: Re: Static analyser grumbling
- From: Kyle Sluder <email@hidden>
- Date: Fri, 23 Aug 2013 08:42:14 -0700
On Aug 23, 2013, at 4:27 AM, Kevin Meaney <email@hidden> wrote:
>
> But my feeling is that the analyzer is talking about context. Normally I'd consider that an object passed into an init method will consume a retain count.
Nope. The only consumed refcount is that of the receiver. How is the analyzer supposed to assume what -initWithFoo: does with its argument? Maybe it's a weak pointer, or perhaps it doesn't use the argument at all. The -init convention only applies to the receiver and the return value.
--Kyle Sluder
_______________________________________________
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