On or about 6/1/10 12:01 PM, thus spake "Kyle Sluder" <[email protected]>:
> On Tue, Jun 1, 2010 at 11:00 AM, Matt Neuburg <[email protected]> wrote: >> So... Are nibs just ignorant of protocols? > > I don't believe the nib loading machinery checks protocol conformance > when it hooks up outlets. It certainly doesn't check class identity, > so I wouldn't expect it to check protocol conformance either. But the nib itself does check class identity; you can't draw an outlet to an instance of the wrong class. So I'm left wondering, then why are you allowed to draw an outlet to an instance of a class that doesn't adopt the required protocol? This feels like a bug to me. And the fact that you can hook up the UIApplication to a delegate that doesn't adopt UIApplicationDelegate and run the app and have everything work, with no complaints at any point, *really* feels like a bug, because in that case what's the protocol for? Maybe I should move this over to Xcode-tools list? I started here because protocols are a Cocoa / language thing, not a tools thing. Wht thnk? m. -- matt neuburg, phd = [email protected], http://www.tidbits.com/matt/ pantes anthropoi tou eidenai oregontai phusei Among the 2007 MacTech Top 25, http://tinyurl.com/2rh4pf AppleScript: the Definitive Guide, 2nd edition http://www.tidbits.com/matt/default.html#applescriptthings Take Control of Exploring & Customizing Snow Leopard http://tinyurl.com/kufyy8 RubyFrontier! http://www.apeth.com/RubyFrontierDocs/default.html TidBITS, Mac news and reviews since 1990, http://www.tidbits.com _______________________________________________ Cocoa-dev mailing list ([email protected]) 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: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to [email protected]
