<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="">I like the proposal also.<div class=""><br class=""><div class="">
<div style="color: rgb(0, 0, 0); letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div style="color: rgb(0, 0, 0); letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div class="">-- </div><div class="">Pierre</div><div class=""><br class=""></div></div></div><br class="Apple-interchange-newline">
</div>
<br class=""><div><blockquote type="cite" class=""><div class="">Le 22 févr. 2016 à 20:16, Evan Maloney via swift-evolution <<a href="mailto:swift-evolution@swift.org" class="">swift-evolution@swift.org</a>> a écrit :</div><br class="Apple-interchange-newline"><div class=""><meta http-equiv="Content-Type" content="text/html charset=us-ascii" class=""><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div class="">Thanks for the feedback, Andrew. I will incorporate it in the next draft, to be sent shortly.</div><div class=""><br class=""></div><div class="">Incidentally, I found Chris Lattner's response about assigning `self`, specifically his statement that "<span style="white-space: pre-wrap; background-color: rgb(255, 255, 255);" class="">this is a compiler bug":</span></div><div class=""><br class=""></div><div class=""><a href="https://lists.swift.org/pipermail/swift-evolution/Week-of-Mon-20160118/007425.html" class="">https://lists.swift.org/pipermail/swift-evolution/Week-of-Mon-20160118/007425.html</a></div><div class=""><br class=""></div><div class=""><br class=""></div><div class=""><br class=""></div><br class=""><div class=""><blockquote type="cite" class=""><div class="">On Feb 20, 2016, at 3:55 AM, Andrew Bennett <<a href="mailto:cacoyi@gmail.com" class="">cacoyi@gmail.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div dir="ltr" class="">Yes, I only learnt about it from Chris Lattner's comment. Great idea to do it right :)<div class=""><br class=""></div><div class="">If I remember correctly I think he said not to rely on it because it wasn't intentional. I'm not sure if he said it was undesirable. I thought it may be worth mentioning in case you didn't know, and because it may help the proposal if it had:<div class=""><ul class=""><li class="">you can already do <font face="monospace, monospace" class="">`self` = self</font>, but it's not officially supported<br class=""></li><li class="">this formalises that ability, and removes the need for backticks</li></ul>Also, you may want to mention that this *<i class="">only</i>* works between `self` and <font face="monospace, monospace" class="">`[weak self]`</font>, ie. you cannot do:<br class=""></div></div><blockquote style="margin:0 0 0 40px;border:none;padding:0px" class=""><div class=""><div class=""><span style="font-family:monospace,monospace" class=""><br class=""></span></div><div class=""><span style="font-family:monospace,monospace" class="">guard self = Optional.Some(123) else { ... }</span></div></div></blockquote><div class=""><div class=""><br class=""></div></div></div><div class="gmail_extra"><br class=""><div class="gmail_quote">On Sat, Feb 20, 2016 at 1:18 PM, Evan Maloney <span dir="ltr" class=""><<a href="mailto:emaloney@gilt.com" target="_blank" class="">emaloney@gilt.com</a>></span> wrote:<br class=""><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">> On Feb 19, 2016, at 8:40 PM, Andrew Bennett via swift-evolution <<a href="mailto:swift-evolution@swift.org" class="">swift-evolution@swift.org</a>> wrote:<br class="">
><br class="">
> A quick note, I'm not sure if it's a hack but you can probably still do this:<br class="">
><br class="">
> guard let `self` = self else { return }<br class="">
<br class="">
</span>IIRC, the fact that this works is accidental and Chris Lattner mentioned that it should be considered a bug.<br class="">
<br class="">
</blockquote></div><br class=""></div>
</div></blockquote></div><br class=""></div>_______________________________________________<br class="">swift-evolution mailing list<br class=""><a href="mailto:swift-evolution@swift.org" class="">swift-evolution@swift.org</a><br class="">https://lists.swift.org/mailman/listinfo/swift-evolution<br class=""></div></blockquote></div><br class=""></div></body></html>