[swift-evolution] [Pitch] separate syntax of class inheritance and protocol conformance
Georgios Moschovitis
george.moschovitis at icloud.com
Sat Jul 23 05:41:58 CDT 2016
> The current syntax establishes a relationship.
>
> X: Y
>
> means "X will have interface of Y". Note there's no mention of inheritance or protocol here: they both establish this relationship. This is why we can use
>
> z is Y
>
> To check whether such relationship holds. Again, there's no need to worry whether Y is a class or protocol.
Totally agree. You shouldn’t care if Y is a class or protocol. You might even want to convert a protocol to a class down the road.
The current syntax is great, no need for changes.
More information about the swift-evolution
mailing list