<div dir="ltr">Replacement for fn4 is just make a tuple inside the closure<div><br><div>let workWithTuple: (Int, Int) -&gt; Void = { doSomething(withTuple: ($0, $1)) }</div></div></div><div class="gmail_extra"><br><div class="gmail_quote">2017-06-07 18:03 GMT+08:00 Adrian Zubarev <span dir="ltr">&lt;<a href="mailto:adrian.zubarev@devandartist.com" target="_blank">adrian.zubarev@devandartist.com</a>&gt;</span>:<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_5928654376245564049bloop_markdown"><p>Well please no:</p>

<p>
<code>
let fn2: ((Int, Int)) -&gt; Void = { lhs, rhs in }   
</code></p>

<p>Instead use destructuring sugar pitched by Chris Lattner on the other thread:</p>

<p><code>let fn2: ((Int, Int)) -&gt; Void = { ((lhs, rhs)) in }</code></p>

<p>That’s a correct error:</p><span class="">

<pre><code>let fn3: (Int, Int) -&gt; Void = { _ in }
</code></pre>

</span><p>This should be allowed, because we might want to work with the whole tuple and not a desctructured elements only:</p>

<pre><code>let fn4: ((Int, Int)) -&gt; Void = { tuple in }
</code></pre><span class="HOEnZb"><font color="#888888">

<p></p></font></span></div><span class="HOEnZb"><font color="#888888"><div class="m_5928654376245564049bloop_original_html"><div id="m_5928654376245564049bloop_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_5928654376245564049bloop_sign_1496829431623208960" class="m_5928654376245564049bloop_sign"><div style="font-family:helvetica,arial;font-size:13px">-- <br>Adrian Zubarev<br>Sent with Airmail</div></div></div><div class="m_5928654376245564049bloop_markdown"><p></p></div></font></span></div></blockquote></div><br></div>