Re: Dictionary keyed by a few sparse integers?
Re: Dictionary keyed by a few sparse integers?
- Subject: Re: Dictionary keyed by a few sparse integers?
- From: Matt Neuburg <email@hidden>
- Date: Sun, 7 Nov 2010 07:51:42 -0800
On Fri, 29 Oct 2010 23:20:11 +1100, Graham Cox <email@hidden> said:
>OK, found the problem - silly mistake. When testing I used alloc + init on the object that implements this, which is not its designated initialiser, so the look-up dictionary wasn't being initialised. D'oh!! (I've also corrected this so that -init does now call the designated initialiser as it should).
I just want to stress the importance of the phrase in parentheses. The docs are quite clear that when you implement a designated initializer different from the inherited designated initializer, you must also override the inherited designated initializer to call your new designated initializer. The docs are also mind-numbingly tedious in their explanation of this point, which can cause one to ignore it. Don't! Graham's experience shows why. 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