I'd find it fantastic if they added<br><br>var list: String... = 1, 2,3,4,5<br><br>However if they remove Variadic arguments then apple would need to remove it from their apis. To name a few...<br><br>print<br>NSPredicate(format:)<br>UIAlertView<br><br>Removing variadic arguments would be a breaking change though. They would either need to remove it quickly or deprecate all the methods that use variadic arguments. Might take awhile before it is removed completely.<br><br><br><div class="gmail_quote"><div dir="ltr">On Sat, Mar 11, 2017 at 4:47 AM Tino Heth via swift-evolution <<a href="mailto:swift-evolution@swift.org">swift-evolution@swift.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word" class="gmail_msg"><div class="gmail_msg"><blockquote type="cite" class="gmail_msg"><div class="gmail_msg"><div class="gmail_msg"><blockquote type="cite" class="gmail_msg"><blockquote type="cite" class="gmail_msg">foo(["a", "b", "c"] as String...) <br class="gmail_msg"></blockquote><br class="gmail_msg">I like this<br class="gmail_msg"></blockquote><br class="gmail_msg">+1<br class="gmail_msg"></div></div></blockquote></div><br class="gmail_msg"></div><div style="word-wrap:break-word" class="gmail_msg"><div class="gmail_msg">I really don't get this:</div><div class="gmail_msg">We have methods like NSLayoutConstraint.activate(_ constraints: [NSLayoutConstraint]), which works with an array, declares its parameter to be array and is called with an array. Quite simple.</div><div class="gmail_msg"><br class="gmail_msg"></div><div class="gmail_msg">On the other hand, we have functions which work with an array, but are declared with <i class="gmail_msg">Type…</i>, and are called with a comma-separated list of elements — and we should add an option to call this function (which works on array!) with an array that is decorated with a strange cast?</div><div class="gmail_msg">That looks extremely awkward to me.</div><div class="gmail_msg"><br class="gmail_msg"></div><div class="gmail_msg">Can I declare a variable like</div><div class="gmail_msg">var list: String… = "a"</div><div class="gmail_msg">?</div><div class="gmail_msg">Imho it's better to get rid of these odd types completely.</div></div>_______________________________________________<br class="gmail_msg">
swift-evolution mailing list<br class="gmail_msg">
<a href="mailto:swift-evolution@swift.org" class="gmail_msg" target="_blank">swift-evolution@swift.org</a><br class="gmail_msg">
<a href="https://lists.swift.org/mailman/listinfo/swift-evolution" rel="noreferrer" class="gmail_msg" target="_blank">https://lists.swift.org/mailman/listinfo/swift-evolution</a><br class="gmail_msg">
</blockquote></div>