[swift-evolution] (no subject)

Chris Lattner clattner at apple.com
Fri Dec 11 22:49:03 CST 2015


> On Dec 11, 2015, at 8:52 AM, John Siracusa via swift-evolution <swift-evolution at swift.org> wrote:
> Chris Lattner wrote:
> When introducing a feature like this, I think it would be useful to survey a range of popular languages (and yes, even perl ;-) to understand what facilities they provide and why (i.e. what problems they are solving) and synthesize a good swift design that can solve the same problems with a hopefully simple approach.
> 
> Travis Tilley wrote:
> ​Perl and Erlang are unique in that valid code in either language looks essentially like line noise. I'd rather take inspiration from languages like ruby, python, and elixir.​
> 
> Jokes aside, the ability to choose delimiters for strings and other language constructs that surround some value is a huge boon to code readability.

I agree.

> My take: once you use a language where you pretty much never have to backslash-escape a character you can easily type to get it into a string, it's really hard to go back. 


In all seriousness, Perl is one of the best languages in the world at text and string processing, and Swift has a lot to learn from it and its community on this topic.  For anyone looking to work on string processing (including string literals and regex's), Perl is really the best game in town.  We have a long ways to go at the moment, but Swift should aspire to be *better* than Perl at string processing and manipulation - comparing to other languages may be interesting but the baseline should be set by Perl.

OTOH, there are some other things that Perl isn’t good at - like shipping on schedule.  Let’s not aspire to following its approach there…  :-)

-Chris
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-evolution/attachments/20151211/c66d0da3/attachment.html>


More information about the swift-evolution mailing list