<div dir="ltr"><div class="gmail_default" style="font-family:trebuchet ms,sans-serif">I'm not in favour of multiline strings. I believe such strings should be stored in plain files and loaded as needed. It makes both the code and the string cleaner to read and maintain. I've had experiences with many languages that offer that resource and I could see what your code can become in terms of maintainability when you have such feature on the language.</div><div class="gmail_default" style="font-family:trebuchet ms,sans-serif"><br></div><div class="gmail_default" style="font-family:trebuchet ms,sans-serif">-1 from me.</div></div><div class="gmail_extra"><br clear="all"><div><div class="gmail_signature"><div dir="ltr">- Leonardo</div></div></div>
<br><div class="gmail_quote">On 12 May 2016 at 01:05, Eduardo Mourey Lopez Ne via swift-evolution <span dir="ltr"><<a href="mailto:swift-evolution@swift.org" target="_blank">swift-evolution@swift.org</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"><div>Something like this might work</div><div><br></div><div style="margin:0px;font-size:11px;line-height:normal;font-family:Menlo;color:rgb(0,132,0)"><span>//string ends on the first line that doesnt start with a "</span></div><div style="margin:0px;font-size:11px;line-height:normal;font-family:Menlo"><span style="color:rgb(0,0,0)">foo( </span><font color="#b51a00"><span>@</span><span>"<?xml version="</span><span>1.0</span><span>"?></span></font></div><div style="margin:0px;font-size:11px;line-height:normal;font-family:Menlo"><span><font color="#b51a00"> "<catalog></font></span></div><div style="margin:0px;font-size:11px;line-height:normal;font-family:Menlo"><font color="#b51a00"><span> </span><span>" <book id="</span><span>bk101</span><span>" empty="</span><span>"></span></font></div><div style="margin:0px;font-size:11px;line-height:normal;font-family:Menlo"><span><font color="#b51a00"> " <author>\(author)</author></font></span></div><div style="margin:0px;font-size:11px;line-height:normal;font-family:Menlo"><span><font color="#b51a00"> " <title>XML Developer's Guide</title></font></span></div><div style="margin:0px;font-size:11px;line-height:normal;font-family:Menlo"><span><font color="#b51a00"> " <genre>Computer</genre></font></span></div><div style="margin:0px;font-size:11px;line-height:normal;font-family:Menlo"><span><font color="#b51a00"> " <price>44.95</price></font></span></div><div style="margin:0px;font-size:11px;line-height:normal;font-family:Menlo"><span><font color="#b51a00"> " <publish_date>2000-10-01</publish_date></font></span></div><div style="margin:0px;font-size:11px;line-height:normal;font-family:Menlo"><span><font color="#b51a00"> " <description>An in-depth look at creating applications with XML.</description></font></span></div><div style="margin:0px;font-size:11px;line-height:normal;font-family:Menlo"><span><font color="#b51a00"> " </book></font></span></div><div style="margin:0px;font-size:11px;line-height:normal;font-family:Menlo"><span><font color="#b51a00"> "</catalog>\n</font></span></div><div style="margin:0px;font-size:11px;line-height:normal;font-family:Menlo"><span> )</span></div><div style="margin:0px;font-size:11px;line-height:normal;font-family:Menlo"><span><br></span></div><div style="margin:0px;font-size:11px;line-height:normal;font-family:Menlo"><span><div style="margin:0px;line-height:normal;color:rgb(0,132,0)"><span>//additionally using a +" could be used to indicate a line break</span></div><div style="margin:0px;line-height:normal"><span><div style="margin:0px;line-height:normal"><span style="color:rgb(0,0,0)">foo( </span><font color="#b51a00"><span>@</span><span>"<?xml version="</span><span>1.0</span><span>"?></span></font></div><div style="margin:0px;line-height:normal"><span><font color="#b51a00"> +"<catalog></font></span></div><div style="margin:0px;line-height:normal"><font color="#b51a00"><span> +</span><span>" <book id="</span><span>bk101</span><span>" empty="</span><span>"></span></font></div><div style="margin:0px;line-height:normal"><span><font color="#b51a00"> +" <author>\(author)</author></font></span></div><div style="margin:0px;line-height:normal"><span><font color="#b51a00"> +" <title>XML Developer's Guide</title></font></span></div><div style="margin:0px;line-height:normal"><span><font color="#b51a00"> +" <genre>Computer</genre></font></span></div><div style="margin:0px;line-height:normal"><span><font color="#b51a00"> +" <price>44.95</price></font></span></div><div style="margin:0px;line-height:normal"><span><font color="#b51a00"> +" <publish_date>2000-10-01</publish_date></font></span></div><div style="margin:0px;line-height:normal"><span><font color="#b51a00"> +" <description>An in-depth look at creating applications with XML.</description></font></span></div><div style="margin:0px;line-height:normal"><span><font color="#b51a00"> +" </book></font></span></div><div style="margin:0px;line-height:normal"><span><font color="#b51a00"> +"</catalog>\n</font></span></div><div style="color:rgb(0,0,0);margin:0px;line-height:normal"><span> )</span></div><div style="color:rgb(0,0,0);margin:0px;line-height:normal"><span><br></span></div></span></div></span></div><div><div class="h5"><div><blockquote type="cite"><div>On May 11, 2016, at 9:48 PM, Ricardo Parada via swift-evolution <<a href="mailto:swift-evolution@swift.org" target="_blank">swift-evolution@swift.org</a>> wrote:</div><br><div><div><br><br>On May 11, 2016, at 2:34 PM, Vladimir.S <<a href="mailto:svabox@gmail.com" target="_blank">svabox@gmail.com</a>> wrote:<br><br><blockquote type="cite"><blockquote type="cite">For example:<br><br><br>letsourceCode =@“NSString *firstName = @“John”;<br> "NSString *lastName = @“Doe”;<br> “NSString *fullName = [NSString stringWithFormat: @“%@<br>%@“, firstName, lastName];"@<br><br>The one that would be a bit of a problem is the closing delimiter,<br></blockquote><br>Yes.. this is why I asked about `"@` - closing delimiter<br>so.. what is the solution in your case ?<br></blockquote><br>Hi Vladimir,<br><br>I don't really have a solution. Perhaps escaping the closing delimiter like this \"@<br><br>It is not pretty but I can't think of anything else. I imagine the other alternatives, i.e. the triple quote `"""` and the quote plus underscore `"_ ` have the same problem. <br><br>If we make the continuation quote required then we don't need a closing delimiter. That would solve the problem. But I've seen several people say they don't like the continuation quote because they want to be able to paste text and not have to worry much about formatting it afterwards. <br>_______________________________________________<br>swift-evolution mailing list<br><a href="mailto:swift-evolution@swift.org" target="_blank">swift-evolution@swift.org</a><br><a href="https://lists.swift.org/mailman/listinfo/swift-evolution" target="_blank">https://lists.swift.org/mailman/listinfo/swift-evolution</a><br></div></div></blockquote></div><br></div></div></div><br>_______________________________________________<br>
swift-evolution mailing list<br>
<a href="mailto:swift-evolution@swift.org">swift-evolution@swift.org</a><br>
<a href="https://lists.swift.org/mailman/listinfo/swift-evolution" rel="noreferrer" target="_blank">https://lists.swift.org/mailman/listinfo/swift-evolution</a><br>
<br></blockquote></div><br></div>