Re: [swift-users] Multiple Class Types in Protocol Composition

2017-12-08 Thread Mario Meili via swift-users
27 To: Mario Meili <mario.me...@live.com> Cc: "swift-users@swift.org" <swift-users@swift.org> Subject: Re: [swift-users] Multiple Class Types in Protocol Composition Hi Mario, You’re right that this part of the proposal was not fully implemented. Computing the common ancest

Re: [swift-users] Multiple Class Types in Protocol Composition

2017-12-07 Thread Slava Pestov via swift-users
Hi Mario, You’re right that this part of the proposal was not fully implemented. Computing the common ancestor of two superclasses is a little tricky here because it would force us to resolve the superclass type of a class when realizing a subclass existential. This would introduce circular

[swift-users] Multiple Class Types in Protocol Composition

2017-12-07 Thread Mario Meili via swift-users
Hi everyone, I noticed strange behaviour of the Swift 4.0.3 compiler regarding class and subtype existentials. According to the proposal SE-0156 (https://github.com/apple/swift-evolution/blob/master/proposals/0156-subclass-existentials.md), multiple class types in protocol compositions should