[swift-evolution] multi-line string literals.
rparada at mac.com
Sun May 8 16:58:46 CDT 2016
The _" and "_ are a good alternative I think.
For some reason the underscore bothers me: it doesn't look as good aesthetically as others, and because it is already used for a couple of other things in Swift (to make large numbers readable and as a placeholder to discard a value).
By the way has the backtick or triple backtick been considered?
> On May 7, 2016, at 7:24 PM, L. Mihalkovic <laurent.mihalkovic at gmail.com> wrote:
> (From mobile)
>> On May 8, 2016, at 12:49 AM, Ricardo Parada via swift-evolution <swift-evolution at swift.org> wrote:
>> It seems to me like this would take care of what is needed 99% of the time.
>> I've seen many who don't favor continuation quotes.
>> The other option could be triple quote """ and make the continuation quote optional. Not using the continuation quote would require the closing triple quote """
> For having built a prototype, I've come to realize that there are more alternatives.
> This is some of my own tests:
> The idea of these M/e or any other similar prefix remind me of my perl days (there were a lot of these), and IMO have little to do with the rest of Swift.
>>> On May 7, 2016, at 9:48 AM, Brent Royal-Gordon via swift-evolution <swift-evolution at swift.org> wrote:
>>> // Something like:
>>> let xml = M"<?xml version="1.0"?>
>>> " <book id="bk101" empty="">
>>> " <author>\(author)</author>
>>> " </book>
>> swift-evolution mailing list
>> swift-evolution at swift.org
More information about the swift-evolution