<div dir="ltr">I agree, and the new format of the swift 4 API docs are much harder to find things in than the swift 3 ones. Perusing all the types and free functions in alphabetical order is so much easier than trying to guess what “topic” something is sorted under.<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Sat, Jul 1, 2017 at 12:54 AM, David Baraff <span dir="ltr"><<a href="mailto:davidbaraff@gmail.com" target="_blank">davidbaraff@gmail.com</a>></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"><br><div><span class=""><blockquote type="cite"><div>On Jun 30, 2017, at 9:48 PM, Taylor Swift via swift-users <<a href="mailto:swift-users@swift.org" target="_blank">swift-users@swift.org</a>> wrote:</div><br class="m_178362936365510373Apple-interchange-newline"><div><div dir="ltr"><br><div class="gmail_extra"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word"><span></span>Swift's strings were very deliberately designed this way. It's tougher to get off the ground, sure, but it's better in the long run.<span class="m_178362936365510373HOEnZb"></span></div>
<br></blockquote></div><br></div><div class="gmail_extra">It probably is, but the correct idiom is not very well known, and sadly most tutorials and unofficial guides are still teaching dumb ways of subscripting into strings (or worse, falling back into NSString methods without mentioning so) so the end result is people writing less performant code rather than more performant code.<br></div></div></div></blockquote><div><br></div></span>An efficient solution doesn’t help if even experienced programmers can’t easily arrive at it. (I’m highly experienced, but I’ll admit I only put in about 5 minutes before I posted that. on the other hand, it shouldn’t take 5 minutes to figure out something that simple with strings. still, maybe i would have done the simple “suffix()” thing had i been looking at the actual swift 4 api’s, but i only had swift 3 api’s in front of me.)</div><span class=""><div><br><blockquote type="cite"><div>
______________________________<wbr>_________________<br>swift-users mailing list<br><a href="mailto:swift-users@swift.org" target="_blank">swift-users@swift.org</a><br><a href="https://lists.swift.org/mailman/listinfo/swift-users" target="_blank">https://lists.swift.org/<wbr>mailman/listinfo/swift-users</a><br></div></blockquote></div><br></span></div></blockquote></div><br></div>