<div dir="ltr">There shouldn&#39;t be a need for a third arrow with regard to purity. Impure encompasses pure in that there is simply no guarantee of purity with an impure function. You should be able to use a pure function in place of an impure function without any issue whatsoever.</div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Feb 17, 2017 at 1:35 PM, Adrian Zubarev via swift-evolution <span dir="ltr">&lt;<a href="mailto:swift-evolution@swift.org" target="_blank">swift-evolution@swift.org</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word"><div class="m_-1934806544047723392bloop_markdown"><p>My suggestion is that <code>-&gt;</code> would be the conditional arrow that can be both <em>pure</em> or <em>impure</em>. That would make <code>@pure func foo(_ f: @pure (Int) -&gt; Int) -&gt; Int</code> equivalent to <code>func foo(_ f: (Int) ~&gt; Int) -&gt; Int</code>. Plus depending on the implementation the compiler <em>might</em> be able to help and tell you that <code>foo</code> could use <code>~&gt;</code> instead.</p>

<p></p></div><div class="m_-1934806544047723392bloop_original_html"><span class=""><div id="m_-1934806544047723392bloop_customfont" style="font-family:Helvetica,Arial;font-size:13px;color:rgba(0,0,0,1.0);margin:0px;line-height:auto"><br></div> <br> <div id="m_-1934806544047723392bloop_sign_1487356322068953088" class="m_-1934806544047723392bloop_sign"><div style="font-family:helvetica,arial;font-size:13px">-- <br>Adrian Zubarev<br>Sent with Airmail</div></div> <br></span><div><div class="h5"><p class="m_-1934806544047723392airmail_on">Am 17. Februar 2017 um 19:25:41, Anton Zhilin (<a href="mailto:antonyzhilin@gmail.com" target="_blank">antonyzhilin@gmail.com</a>) schrieb:</p> <blockquote type="cite" class="m_-1934806544047723392clean_bq"><span><div><div></div><div>





<div dir="ltr">
<div class="m_-1934806544047723392markdown-here-wrapper">
<p style="margin:0px 0px 1.2em!important">Just let</p>
<pre style="font-family:Consolas,Inconsolata,Courier,monospace;line-height:1.2em;margin:1.2em 0px"><code style="font-family:Consolas,Inconsolata,Courier,monospace;margin:0px 0.15em;background-color:rgb(248,248,248);white-space:pre-wrap;overflow:auto;border-radius:3px;border:1px solid rgb(204,204,204);padding:0.5em 0.7em;display:block!important">@pure func foo(_ f: (Int) -&gt; Int) -&gt; Int<span style="font-size:0.85em">
</span></code></pre>
<p style="margin:0px 0px 1.2em!important">be the same as those two
combined:</p>
<pre style="font-family:Consolas,Inconsolata,Courier,monospace;line-height:1.2em;margin:1.2em 0px"><code style="font-family:Consolas,Inconsolata,Courier,monospace;margin:0px 0.15em;background-color:rgb(248,248,248);white-space:pre-wrap;overflow:auto;border-radius:3px;border:1px solid rgb(204,204,204);padding:0.5em 0.7em;display:block!important">@pure func foo(_ f: @pure (Int) -&gt; Int) -&gt; Int
func foo(_ f: (Int) -&gt; Int) -&gt; Int<span style="font-size:0.85em">
</span></code></pre>
<p style="margin:0px 0px 1.2em!important">No need for anything like
“re-pure” or <code style="font-family:Consolas,Inconsolata,Courier,monospace;margin:0px 0.15em;padding:0px 0.3em;white-space:pre-wrap;border:1px solid rgb(234,234,234);background-color:rgb(248,248,248);border-radius:3px;display:inline">
≃&gt;</code>.</p>
<div title="MDH:PGRpdj5KdXN0IGxldDwvZGl2PjxkaXY+PGJyPjwvZGl2PjxkaXY+YGBgPC9kaXY+PGRpdj5AcHVy ZSBmdW5jIGZvbyhfIGY6IChJbnQpIC0mZ3Q7IEludCkgLSZndDsgSW50PGJyPjwvZGl2PjxkaXY+ YGBgPC9kaXY+PGRpdj48YnI+PC9kaXY+PGRpdj5iZSB0aGUgc2FtZSBhcyB0aG9zZSB0d28gY29t YmluZWQ6PC9kaXY+PGRpdj48YnI+PC9kaXY+PGRpdj5gYGA8L2Rpdj48ZGl2PjxkaXY+QHB1cmUg ZnVuYyBmb28oXyBmOiBAcHVyZSAoSW50KSAtJmd0OyBJbnQpIC0mZ3Q7IEludDwvZGl2PjxkaXY+ ZnVuYyBmb28oXyBmOiAoSW50KSAtJmd0OyBJbnQpIC0mZ3Q7IEludDwvZGl2PjwvZGl2PjxkaXY+ YGBgPC9kaXY+PGRpdj48YnI+PC9kaXY+PGRpdj5ObyBuZWVkIGZvciBhbnl0aGluZyBsaWtlICJy ZS1wdXJlIiBvciBg4omDJmd0O2AuPC9kaXY+" style="height:0;width:0;max-height:0;max-width:0;overflow:hidden;font-size:0em;padding:0;margin:0">
​</div>
</div>
</div>


</div></div></span></blockquote></div></div></div><div class="m_-1934806544047723392bloop_markdown"><p></p></div></div><br>______________________________<wbr>_________________<br>
swift-evolution mailing list<br>
<a href="mailto:swift-evolution@swift.org">swift-evolution@swift.org</a><br>
<a href="https://lists.swift.org/mailman/listinfo/swift-evolution" rel="noreferrer" target="_blank">https://lists.swift.org/<wbr>mailman/listinfo/swift-<wbr>evolution</a><br>
<br></blockquote></div><br></div>