String Syntax

Strings can be quoted or not (using "). If the string contains white space, then it must be quoted. For example:

Hi there!

This would be parsed as two strings: "Hi" and "there!". But the following is one string:

"Hi there!"

If a string begins with quotes, but does not end with a quote (before end of file), then failbit will be set. This may nor may not cause a runtime error to be thrown (depending on the context).

Any of the escape sequences described under character syntax are allowed within strings. But within strings, single quotes do not delimit characters. Instead single quotes are just another character in the string. Note that you can use \" to place the string quote character within a string.