[swift-evolution] [RFC] #Self

Matthew Johnson matthew at anandabits.com
Tue May 10 11:28:01 CDT 2016



Sent from my iPad

> On May 10, 2016, at 11:12 AM, Timothy Wood <tjw at me.com> wrote:
> 
> 
>> On May 10, 2016, at 9:05 AM, Matthew Johnson <matthew at anandabits.com> wrote:
>> 
>> It isn't at all the same.  Self is covariant with the dynamic context.  #Self, #Type, #StaticType or whatever we call it is statically determined by the lexical context.
> 
> Yes. That is what the # distinguishes, in my original suggesting for the previous proposal. Using a different term altogether introduces more ambiguity by raising questions about what other ways the two  things differ. With `#Self`, I read that naturally as the compile-time (“#”) version of the thing being compiled (“Self”).

Yep, understood.  It's perfectly clear to me but I understand why Chris is concerned about it having potential to confuse people.  It is a pretty subtle difference especially since Self and #Self are the same in some contexts.  In any case, I would be content to live with any name that wins out.

> 
> -tim
> 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-evolution/attachments/20160510/2efb3434/attachment.html>


More information about the swift-evolution mailing list