Re: Cocoa and messages to nil, revisited
Re: Cocoa and messages to nil, revisited
- Subject: Re: Cocoa and messages to nil, revisited
- From: Daniel Jalkut <email@hidden>
- Date: Wed, 8 Aug 2007 01:47:17 -0400
On Aug 7, 2007, at 7:35 PM, Jeff Laing wrote:
As a performance junkie, its disappointing that people still think
that its
quicker to just send the message to nil, than to do "if (target)
[target
message];" since it doesn't matter *how* fast you make that message
dispatcher, it can't possibly be faster than the two instructions
that the
conditional takes
Doesn't matter. Sending messages to nil is easier to read and well
established as generally safe in Cocoa. The areas where it is unsafe
are well documented. I enjoy sending messages to nil. Obviously so
does much of Apple, and I'm sure much of the rest of the Cocoa
developer world.
Performance on the level you describe is generally not worth
considering. (It's not worth it for the "people" who use nil messaging
as a pro-performance argument, either!)
Daniel
_______________________________________________
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