<html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><br class=""><div><br class=""><blockquote type="cite" class=""><div class="">On Dec 1, 2017, at 10:07 AM, Greg Titus &lt;<a href="mailto:greg@omnigroup.com" class="">greg@omnigroup.com</a>&gt; wrote:</div><br class="Apple-interchange-newline"><div class=""><meta http-equiv="Content-Type" content="text/html; charset=utf-8" class=""><div style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><br class=""><div class=""><br class=""><blockquote type="cite" class=""><div class="">On Dec 1, 2017, at 9:11 AM, Ben Langmuir via swift-evolution &lt;<a href="mailto:swift-evolution@swift.org" class="">swift-evolution@swift.org</a>&gt; wrote:</div><div class=""><div style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class=""><div class="">Hey Doug,</div><div class=""><br class=""></div><div class="">I'm very much in favour of reducing the scope of associated type inference. &nbsp;Can you outline why you believe that (3) is necessary? &nbsp;If I am following correctly, if we had (1) and (2) the only thing you'd need to add to the "minimal collection" implementation would be a typealias for `Element`, which seems reasonable to me.</div><div class=""><br class=""></div><div class="">Ben</div></div></div></blockquote></div><br class=""><div class="">If nothing else, dropping (3) would be source breaking for 90%+ of current associated type uses. Whereas even the very minimal inference in (3) probably brings that figure down to 1% or so (outside of the stdlib, which would need to adopt a bunch of (2)). Obviously these percentages are just my guesses and not based on any real survey, but certainly would be the case for all Swift code I’ve seen.</div></div></div></blockquote><br class=""></div><div>Many of the associated-type inference bugs I’ve seen were from people expecting something like (3), but the current implementation either fails to infer anything (the common case!) or we get inference from some seemingly-unrelated place. I included (3) specifically because I think taking away (3) will break source compatibility significantly (as Greg suggests)… and despite the fact that the complexity of implementation for (3) is fairly high.</div><div><br class=""></div><div><span class="Apple-tab-span" style="white-space:pre">        </span>- Doug</div><div><br class=""></div><br class=""></body></html>