> On Aug 3, 2016, at 1:57 AM, Tino Heth <[email protected]> wrote: > >> Since RangeExpression is a protocol compatible with any index type, it has >> to have an associated type > I haven't read all linked information, but would the situation change with > generic protocols? > Thinks like "AnyGenerator" afaics would be superfluous if we had "protocol > Generator<Type>", and the same might be true for RangeExpression.
No, this is not an appropriate use case for generic protocols. (Nor is Generator/IteratorProtocol, for that matter.) Generic protocols would be for cases where a single concrete instance can conform to a protocol using several different types. Genuine use cases for that do exist, but they're few and far between. -- Brent Royal-Gordon Architechies _______________________________________________ swift-evolution mailing list [email protected] https://lists.swift.org/mailman/listinfo/swift-evolution
