[swift-evolution] [RFC] Associated type inference

Howard Lovatt howard.lovatt at gmail.com
Sat Dec 2 20:33:43 CST 2017


We also know that the current situation isn’t acceptable to a great proposition of the community, that is why we are still discussing the issue!

A notable example of reversal of an evolution decision is String’s conformance to Collection. Which I think on the 2nd attempt was a much better decision. 

For requiring typedefs for associated types, a fix it and error would be quite successful, e.g. Xcode already suggests the typedefs (which I currently accept before letting Xcode insert blanks for the missing methods etc.).

-- Howard. 

> On 3 Dec 2017, at 8:15 am, Xiaodi Wu <xiaodi.wu at gmail.com> wrote:
> 
>> On Sat, Dec 2, 2017 at 2:30 PM, Howard Lovatt via swift-evolution <swift-evolution at swift.org> wrote:
>> Definitely in favour of doing something, I always define the associated types since I have had so much trouble with the inference.
>> 
>> Personally I would prefer just 1 and 2 and forget 3. I know this would break a lot of code, but I think we should do that because it is the lesser of the evils.
> 
> As Doug wrote, an approach that's essentially that was reviewed and rejected in SE-0108. We already know that it's not acceptable to a great proportion of the community.
> 
> 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-evolution/attachments/20171203/17760577/attachment.html>


More information about the swift-evolution mailing list