Am 2016-12-06 15:39, schrieb Daniel Leping:
Does not this make associatedtype redundant additional complexity?

No, they serve a different use case.

Generic Type Parameters are used to create a new type from a parameterized template.
The user always has to be explicit about these parameters.

Associated types are used to create one protocol with constraints (where the protocol allows for some controlled variability in the conforming class/struct). Here the associated types are inferred from the conforming type automatically.

--
Martin
_______________________________________________
swift-evolution mailing list
swift-evolution@swift.org
https://lists.swift.org/mailman/listinfo/swift-evolution

Reply via email to