<html><head><meta http-equiv="content-type" content="text/html; charset=utf-8"></head><body dir="auto"><div></div><div>Sorry I left mutating off by mistake. I'm referring to the call site more</div><div><br>On Apr 22, 2016, at 8:40 AM, Krishna Kumar &lt;<a href="mailto:kkdevenda@gmail.com">kkdevenda@gmail.com</a>&gt; wrote:<br><br></div><blockquote type="cite"><div><meta http-equiv="Content-Type" content="text/html charset=utf-8">Hey<div class=""><br class=""></div><div class="">I think adding “&amp;” to methods will reduce the readability of the code. Also, keyword “mutating” makes it super clear and readable that my method is mutating the values.</div><div class=""><br class=""></div><div class="">1. mutating func add(value: Double){…}</div><div class=""><br class=""></div><div class="">2. func add&amp;(value: Double){…}</div><div class=""><br class=""></div><div class="">I think it’s easy to skip the information encoded into the 2nd function which is this function is mutating a value as compared to 1st. When I read 1st function I start reading with keyword “mutating” making its intentions clear to me.</div><div class=""><br class=""></div><div class="">Also, it might become a symbol nightmare with following type signature of a function-</div><div class=""><br class=""></div><div class="">func nightmare&amp;(title: String?) -&gt; String? -&gt; String?{…}</div><div class=""><br class=""></div><div class="">I can see the advantage of using “&amp;” when calling a function. It makes clear at the call site that this method is mutating but still I don’t find eliminating “mutating” a good step for the reasons mentioned above.</div><div class=""><br class=""></div><div class="">Maybe we can think of some better solution.</div><div class=""><br class=""></div><div class="">Thanks</div><div class=""><br class=""></div><div class="">-Krishna</div><div class=""><br class=""></div><div class=""><div><blockquote type="cite" class=""><div class="">On Apr 21, 2016, at 10:38 PM, Daniel Steinberg via swift-evolution &lt;<a href="mailto:swift-evolution@swift.org" class="">swift-evolution@swift.org</a>&gt; wrote:</div><br class="Apple-interchange-newline"><div class=""><a href="mailto:swift-evolution@swift.org" style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; 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;" class="">swift-evolution@swift.org</a></div></blockquote></div><br class=""></div></div></blockquote></body></html>