Multiline stings

Most other scripting languages offer some kind of multi-line string support. The general term for this is "here document", see: https://en.wikipedia.org/wiki/Here_document

I thought this would be a nice feature to add to SmallBASIC. I decided I liked the Python syntax style and this turned out to be fairly straight forward to implement. A multi-line string is declared by enclosing it in triple quotes (double quotes only). The syntax looks like this:

s1= """
hello
hello
hello
"""

If you call PRINT s1, the output includes new line characters. These can be excluded by escaping the line end character, like this:

s1= """\
hello\
hello\
hello\
"""

As part of this change, a single string may also be created from multiple quoted strings on separate lines, like this:

s2="hello"
"hello"
"hello"

This should make it easier for example to embed XPM bitmap images.

The multiline string does look like a nice addition!

This is so far a display facility, without the other 'over-loading' of Here Document?

Thx!

SB if finds the & at the end of the line then it adds the next line.

a = &
"1234" + &
"5678"
? a

This prints

12345678

I would prefer (in preprocessor stage) something like


s = &<
line 1
...
line n
&>

&" and &", it would be nice too.
I select the '&' since it is already used in SB.