<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div class="">Actually that could cause more ambiguity if a type String is created inside ModuleA or ModuleB for example. So yeah, I think “from” keyword would be the best option actually. :(</div><div class=""><br class=""></div><br class=""><div><blockquote type="cite" class=""><div class="">On Jun 7, 2016, at 5:23 PM, Paulo Faria &lt;<a href="mailto:paulo@zewo.io" class="">paulo@zewo.io</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; -webkit-line-break: after-white-space;" class=""><br class=""><div class=""><br class=""><blockquote type="cite" class=""><div class="">Begin forwarded message:</div><br class="Apple-interchange-newline"><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px;" class=""><span style="font-family: -webkit-system-font, 'Helvetica Neue', Helvetica, sans-serif;" class=""><b class="">From: </b></span><span style="font-family: -webkit-system-font, Helvetica Neue, Helvetica, sans-serif;" class="">Paulo Faria &lt;<a href="mailto:paulo@zewo.io" class="">paulo@zewo.io</a>&gt;<br class=""></span></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px;" class=""><span style="font-family: -webkit-system-font, 'Helvetica Neue', Helvetica, sans-serif;" class=""><b class="">Subject: </b></span><span style="font-family: -webkit-system-font, Helvetica Neue, Helvetica, sans-serif;" class=""><b class="">Re: [swift-evolution] Name disambiguation of computed property/function with same type defined in extensions</b><br class=""></span></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px;" class=""><span style="font-family: -webkit-system-font, 'Helvetica Neue', Helvetica, sans-serif;" class=""><b class="">Date: </b></span><span style="font-family: -webkit-system-font, Helvetica Neue, Helvetica, sans-serif;" class="">June 7, 2016 at 4:08:16 PM GMT-3<br class=""></span></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px;" class=""><span style="font-family: -webkit-system-font, 'Helvetica Neue', Helvetica, sans-serif;" class=""><b class="">To: </b></span><span style="font-family: -webkit-system-font, Helvetica Neue, Helvetica, sans-serif;" class="">Brent Royal-Gordon &lt;<a href="mailto:brent@architechies.com" class="">brent@architechies.com</a>&gt;<br class=""></span></div><br class=""><div class=""><div class="">Yeah! I really like that option. no new keyword and it makes a lot of sense cause look at the error message:<br class=""><br class="">error: ambiguous use of 'capitalized()'<br class="">let capitalized = "hello swift".capitalized()<br class=""> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;^<br class="">ModuleA.String:2:17: note: found this candidate<br class=""> &nbsp;&nbsp;&nbsp;public func capitalized() -&gt; String<br class=""> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;^<br class="">ModuleB.String:2:17: note: found this candidate<br class=""> &nbsp;&nbsp;&nbsp;public func capitalized() -&gt; String<br class=""><br class=""><br class="">Specifically ModuleA.String:2:17 and ModuleB.String:2:17. So it seems to me that Brent's proposal makes a lot of sense actually!<br class=""><br class=""><blockquote type="cite" class="">On Jun 7, 2016, at 8:24 AM, Brent Royal-Gordon &lt;<a href="mailto:brent@architechies.com" class="">brent@architechies.com</a>&gt; wrote:<br class=""><br class=""><blockquote type="cite" class="">I want to discuss the problem of name ambiguity when a computed property or function is defined with the same name and type in different modules. Currently there’s no way to disambiguate the implementation in use cases similar to the one contained in the gist below.<br class=""><br class=""><a href="https://gist.github.com/paulofaria/f48d0b847a0fb7c125d163d0e349500a" class="">https://gist.github.com/paulofaria/f48d0b847a0fb7c125d163d0e349500a</a><br class=""><br class="">The gist also contains some informal proposals. The idea is to create a formal proposal based on the discussion that shall follow.<br class=""></blockquote><br class="">We already have the concept of prefixing a type name with a module to disambiguate when two modules have the same type. I wonder if we could do the same thing to disambiguate between conflicting extensions?<br class=""><br class=""><span class="Apple-tab-span" style="white-space:pre">        </span>import ModuleA<br class=""><span class="Apple-tab-span" style="white-space:pre">        </span>import ModuleB<br class=""><span class="Apple-tab-span" style="white-space:pre">        </span><br class=""><span class="Apple-tab-span" style="white-space:pre">        </span>("hello world" as ModuleA.String).capitalized()<span class="Apple-tab-span" style="white-space:pre">        </span>// Swift.String, with only APIs known to ModuleA<br class=""><span class="Apple-tab-span" style="white-space:pre">        </span>("hello world" as ModuleB.String).capitalized()<span class="Apple-tab-span" style="white-space:pre">        </span>// Swift.String, with only APIs known to ModuleB<br class=""><span class="Apple-tab-span" style="white-space:pre">        </span>"hello world".capitalized()<span class="Apple-tab-span" style="white-space:pre">        </span><span class="Apple-tab-span" style="white-space:pre">        </span><span class="Apple-tab-span" style="white-space:pre">        </span><span class="Apple-tab-span" style="white-space:pre">        </span><span class="Apple-tab-span" style="white-space:pre">        </span>// Still causes a compile-time error for ambiguity<br class=""><br class="">-- <br class="">Brent Royal-Gordon<br class="">Architechies<br class=""><br class=""></blockquote><br class=""></div></div></blockquote></div><br class=""></div></div></blockquote></div><br class=""></body></html>