<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><blockquote type="cite" class=""><div class="">On 04 Jun 2016, Erica Sadun wrote:</div><br class="Apple-interchange-newline"><div class=""><div class="">Discussion has more or less drawn down. Are there any further significant requests / issues that need addressing? Both standalone functions (my recommended approach) &nbsp;and the MemoryLayout&lt;T&gt; struct approach (alternative, with reasons why I think it's not as ideal) are discussed in-proposal.<br class=""><br class="">Pull Request: <a href="https://github.com/apple/swift-evolution/pull/350" class="">https://github.com/apple/swift-evolution/pull/350</a><br class=""></div></div></blockquote></div><br class=""><div class=""><div class="">Good proposal, Erica!</div><div class=""><br class=""></div><div class="">Regardless of the little input I've given to this discussion, I actually prefer the set of `<font face="Menlo" class="">memory*</font>` prefixed top-level functions to a `<font face="Menlo" class="">MemoryLayout</font>` struct or tuple.</div><div class=""><br class=""></div><div class="">However, I think it's most common to call these functions with a type argument, and we should thus stick to the practice of keeping that use case short, and the call-with-value case explicit. In particular, I'd avoid the label for a type argument, and say `<font face="Menlo" class="">ofValue:</font>` when passing a value:</div><div class=""><br class=""></div><div class=""><font face="Menlo" class="">&nbsp; &nbsp; memorySize(ofType:) &nbsp; &nbsp; &nbsp;→ memorySize(<b class="">_:</b>)</font></div><div class=""><font face="Menlo" class="">&nbsp; &nbsp; memorySize(of:) &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;→ memorySize(<b class="">ofValue:</b>)</font></div><div class=""><font face="Menlo" class="">&nbsp; &nbsp; memoryInterval(ofType:) &nbsp;→ memoryInterval(<b class="">_:</b>)</font></div><div class=""><font face="Menlo" class="">&nbsp; &nbsp; memoryInterval(of:) &nbsp; &nbsp; &nbsp;→ memoryInterval(<b class="">ofValue:</b>)</font></div><div class=""><font face="Menlo" class="">&nbsp; &nbsp; memoryAlignment(ofType:) →&nbsp;memoryAlignment(<b class="">_:</b>)</font></div><div class=""><font face="Menlo" class="">&nbsp; &nbsp; memoryAlignment(of:) &nbsp; &nbsp; →&nbsp;memoryAlignment(<b class="">ofValue:</b>)</font></div><div class=""><br class=""></div><div class="">Secondly, (this might be over-engineering but) would it still make sense to use `<font face="Menlo" class="">@autoclosure</font>` in the `<font face="Menlo" class="">ofValue:</font>` functions because they don't really need their arguments evaluated?</div><div class=""><br class=""></div><div class=""><font face="Menlo" class="">&nbsp; &nbsp;&nbsp;<b class="">public&nbsp;func</b>&nbsp;memorySize&lt;T&gt;(ofValue _:&nbsp;<b class="">@autoclosure</b>&nbsp;T -&gt; ())&nbsp;-&gt;&nbsp;Int</font></div><div class=""><font face="Menlo" class="">&nbsp; &nbsp;&nbsp;<b class="">public&nbsp;func</b>&nbsp;memoryInterval&lt;T&gt;(ofValue _:&nbsp;<b class="">@autoclosure</b>&nbsp;T -&gt; ())&nbsp;-&gt;&nbsp;Int</font></div><div class=""><font face="Menlo" class="">&nbsp; &nbsp;&nbsp;<b class="">public&nbsp;func</b>&nbsp;memoryAlignment&lt;T&gt;(ofValue _:&nbsp;<b class="">@autoclosure</b>&nbsp;T -&gt; ())&nbsp;-&gt;&nbsp;Int</font></div><div class=""><br class=""></div><div class="">— Pyry, whose name gets autocoerced in various ways apparently.</div></div><div class=""><br class=""></div></body></html>