RE: Initialisation pattern
RE: Initialisation pattern
- Subject: RE: Initialisation pattern
- From: André Francisco <email@hidden>
- Date: Thu, 13 Aug 2015 03:48:17 +0000
- Importance: Normal
I've read that too :) still, the problem sticks. I'm writing a framework, not an app, so it's important that callers initialise objects properly. And I wish I was using swift, honestly.
Subject: Re: Initialisation pattern
From: email@hidden
Date: Wed, 12 Aug 2015 20:22:36 -0700
CC: email@hidden
To: email@hidden
On Aug 12, 2015, at 8:07 PM, André Francisco <email@hidden> wrote:I've been reading about object initialisation in Objective-c, as well as the recent additions of NS_UNAVAILABLE and NS_DESIGNATED_INITIALIZER. It's been confusing what the correct approach would be, mostly due to limitations imposed by the compiler. My main goal is obviously to ensure proper object initialisation, both when an object is directly instantiated and when a constructor call is propagated by a child subclass.
Don’t sweat it — you may be overthinking this. In practice it’s not a big problem (I’ve only run into issues related to this a few times), and in the long run it’s fixed by Swift.
—Jens
_______________________________________________
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