On Wed, Feb 4, 2009 at 10:03 AM, Steve Cronin <steve_cro...@mac.com> wrote: > Well, sheesh - that's embarrassing! There is no 'self' until init - I know > that! Ugh.
Sure there is. There's a 'self' in every method. It refers to the receiver of the message that was sent. In instance methods, 'self' refers to the instance. In class methods, 'self' refers to the class. Example: @implementation Foo + foo { NSLog(@"self is %@ (%p) and Foo is %@ (%p)", self, self, [Foo class], [Foo class]); } @end You'll get the same values for both, since they give you the same thing. Of course it's the class, not the instance, so the self you have isn't the self you *wanted* here. Mike _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) 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 arch...@mail-archive.com