> On 6 Sep 2015, at 21:19, Quincey Morris <quinceymor...@rivergatesoftware.com> > wrote: > > I’ve been thinking about the implications of this for a couple of days now. > Of course, you should file a Radar if you see some compiler behavior that > looks like it ought to work. But I think there’s a higher order problem > that’s worth noting. > > In my experience (which is to say, after a couple of months spent converting > a fair-sized app from Obj-C to Swift), converting an Obj-C implementation to > directly an “equivalent” Swift implementation is a lousy experience with poor > results. There are several waves of consequences from the attempt: > > 1. You struggle to find a Swift equivalent of your Obj-C code. It takes > forever. > > 2. You find your equivalent code ends up wordier and somehow more > "unfactored" than the Obj-C code, even though it is somehow “the same”. You > hate using it. > > 3. You fiddle with the Swift implementation (leaving Obj-C behind, finally) > to make it a bit more streamlined. It takes forever. > > 4. You crash the compiler AND SourceKit, because you’ve ventured into > uncharted territory in order to hide an Obj-C-derived mess behind Swift > syntax. You have to look for workarounds at least until the next Xcode beta. > Very interesting indeed. This is the sort of ‘from the trenches' report we need.
I did a few days work on my own fair substantially app with regard to Swift integration / conversion and made a reluctant gut instinct decision to stay with Obj-C (even though I really wanted to utilise Swift). There was just too much stuff (KVO, bindings etc) that didn’t feel like a good fit with Swift within an established project. Jonathan _______________________________________________ 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: https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com