Re: [swift-evolution] [RFC][Proposal] Ease restrictions on protocol nesting

2017-02-17 Thread Karl Wagner via swift-evolution
Anybody from core-team able to weigh in: do we want to keep this rule of not allowing parametrised protocols (in which case nesting is "trivial" - capturing is not allowed, only one protocol exists, so it's just namespacing), or is this something which should be deferred? If

Re: [swift-evolution] [RFC][Proposal] Ease restrictions on protocol nesting

2017-02-07 Thread Matthew Johnson via swift-evolution
> On Feb 6, 2017, at 11:12 PM, Karl Wagner via swift-evolution > wrote: > > >> On 7 Feb 2017, at 06:05, Slava Pestov > > wrote: >> >>> >>> On Feb 6, 2017, at 9:00 PM, Karl Wagner via swift-evolution >>> mailto:swift-evolution@swift.org>> wrote: >>> - Nested protoco

Re: [swift-evolution] [RFC][Proposal] Ease restrictions on protocol nesting

2017-02-07 Thread Karl Wagner via swift-evolution
> On 7 Feb 2017, at 06:18, Slava Pestov wrote: > >> >> On Feb 6, 2017, at 9:12 PM, Karl Wagner > > wrote: >> >> >>> On 7 Feb 2017, at 06:05, Slava Pestov >> > wrote: >>> On Feb 6, 2017, at 9:00 PM, Karl Wagner via swift-evolutio

Re: [swift-evolution] [RFC][Proposal] Ease restrictions on protocol nesting

2017-02-06 Thread Slava Pestov via swift-evolution
> On Feb 6, 2017, at 9:12 PM, Karl Wagner wrote: > > >> On 7 Feb 2017, at 06:05, Slava Pestov > > wrote: >> >>> >>> On Feb 6, 2017, at 9:00 PM, Karl Wagner via swift-evolution >>> mailto:swift-evolution@swift.org>> wrote: >>> - Nested protocols in generic types are

Re: [swift-evolution] [RFC][Proposal] Ease restrictions on protocol nesting

2017-02-06 Thread Karl Wagner via swift-evolution
> On 7 Feb 2017, at 06:05, Slava Pestov wrote: > >> >> On Feb 6, 2017, at 9:00 PM, Karl Wagner via swift-evolution >> mailto:swift-evolution@swift.org>> wrote: >> - Nested protocols in generic types are not parameterised by the parent's >> generic parameters. > So if I write GenericType.SomeP

Re: [swift-evolution] [RFC][Proposal] Ease restrictions on protocol nesting

2017-02-06 Thread Slava Pestov via swift-evolution
> On Feb 6, 2017, at 9:00 PM, Karl Wagner via swift-evolution > wrote: > - Nested protocols in generic types are not parameterised by the parent's > generic parameters. So if I write GenericType.SomeProto and GenericType.SomeProto, is it the same protocol? What about GenericType.SomeProto, is

[swift-evolution] [RFC][Proposal] Ease restrictions on protocol nesting

2017-02-06 Thread Karl Wagner via swift-evolution
The proposal has been refined since the previous discussions. In particular: - No capturing is allowed between nested types (beyond what already exists for nested generics). - Access control for nested types in protocols. - Nested types in constrained protocol extensions mean the same as in unco