Re: accelerometer puzzle
Re: accelerometer puzzle
- Subject: Re: accelerometer puzzle
- From: Matt Neuburg <email@hidden>
- Date: Wed, 1 Dec 2010 07:41:10 -0800
On Mon, 29 Nov 2010 12:39:52 -0800, David Duncan <email@hidden> said:
>Objective-C is a dynamic enough language that it cannot fully check for conformance at compile time (which is why the message above is a warning and not an error). Technically you don't even need to conform to the protocol, you can just implement the methods and go, but implementing the protocol allows for error checking by the compiler but only when the compiler can actually see the protocol declarations in the first place (which is not the case above).
Still, the OP has a point. If everything in a protocol is optional, then (1) why should the compiler care whether we formally adopt the protocol or not, and (2) what sort of "error checking" could the compiler do? In other words I'm suggesting that there should be no warning unless the protocol has required methods. m.
--
matt neuburg, phd = email@hidden, <http://www.apeth.net/matt/>
A fool + a tool + an autorelease pool = cool!
AppleScript: the Definitive Guide - Second Edition!
http://www.apeth.net/matt/default.html#applescriptthings_______________________________________________
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