lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]




On 31/08/16 07:22 PM, Sam Putman wrote:


On Wed, Aug 31, 2016 at 11:21 AM, Soni L. <fakedme@gmail.com <mailto:fakedme@gmail.com>> wrote:


    With the exception of ASCII NUL, no other character breaks
    strings. Also multiline strings don't support escapes and it'd be
    nice to have an alternative that does.


Sure would, allow me to offer you such an alternative:

mystring = "Hi Soni. I'm a multi-line string!\n"
             ..  "I'm convenient, \t offer escapes, and more!\n"
             ..  "By the way, do you have a repo or something?\n"
.. "Because I'm starting to wonder whether you write software,\n"
             ..  "Or just write *about* software...\n"

mystring = "Hi Sam. I'm also a multi-line string!\n\z
            except I'm better! I take less bytes to type,\n\z
            and still provide the same newlineness!\n\z
However, I cannot be used in the REPL, as it doesn't like me.\n\z
            This is also nowhere near as nice as Rust's strings.\n\z
But yes, I do have a github, it's SoniEx2. I don't use it anymore, BitBucket is better.\n"


You're welcome!


--
Disclaimer: these emails may be made public at any given time, with or without reason. If you don't agree with this, DO NOT REPLY.