Re:Swift 2.2 Released
by AsyncAwait on Tuesday March 22, 2016 @05:52AM
(#11335397)
Yeah, somewhat related to that; it's not currently possible to have typealias for a type with generic parameters, one has to wrap it in a struct or an enum, however Swift is very much not done and they're catching up quickly, so I'm optimistic, especially now that we can see and affect what's coming next.
Re:Swift 2.2 Released
by melloclello on Tuesday March 22, 2016 @06:48AM
(#11335569)
Generic typealiases are coming, thank goodness: http://ericasadun.com/2016/03/08/generic-typealiases-are-a-t...
Re:Swift 2.2 Released
by AsyncAwait on Tuesday March 22, 2016 @08:08AM
(#11335849)
Awesome!
This is what I'm talking about; now that Swift is open-source we can see which improvements have landed and what is coming next.
Thanks for the link.
There's a way to dance around that restriction, by making an intermediate class to do type erasure by hand (why I should do that? That's compiler's job), but still - Swift crew are obviously very talented bunch with a good taste, how they allowed such nonsense from the start?
PS I don't want to sound too negative, Swift replaced C# as my favorite language, 95% of the time it's joy to use (especially after Objective C, I never agreed with that language), it's just - the generic protocol thing drives me mad.