[swift-evolution] [Review] SE-0156: Class and Subtype existentials

Matthew Johnson matthew at anandabits.com
Tue Feb 28 15:45:33 CST 2017

> What is your evaluation of the proposal?
+1, this is a fantastic proposal!  I

The proposal does not specifically call out whether a class may inherit from a subclass of a superclass constraint when a typealias is used in the inheritance list.  I believe the following should be valid, but it would be a good idea to make that explicit:

class B {}
class D: B {}
protocol P {}
typealias BP = B & P

class Foo: D, BP

> Is the problem being addressed significant enough to warrant a change to Swift?
Yes, we are not able to correctly import class constrained protocols from Objective-C.

> Does this proposal fit well with the feel and direction of Swift?
Very much.

> If you have used other languages or libraries with a similar feature, how do you feel that this proposal compares to those?

> How much effort did you put into your review? A glance, a quick reading, or an in-depth study?
In-depth study of the original drafts.  Quick read of the final review proposal.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-evolution/attachments/20170228/4f3d6aca/attachment.html>

More information about the swift-evolution mailing list