From ef14bd0e49bec4025b80bdc01638b7a34b7778de Mon Sep 17 00:00:00 2001 From: Kaz Kylheku Date: Sat, 15 Mar 2014 17:43:45 -0700 Subject: Document that leading whitespace before a backslash line continuator is also deleted in string literals. --- txr.1 | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) (limited to 'txr.1') diff --git a/txr.1 b/txr.1 index 08806828..1a7a7e4c 100644 --- a/txr.1 +++ b/txr.1 @@ -1111,11 +1111,24 @@ as a delimiter. Thus, "\ex21;;" represents "!;". If the line ends in the middle of a literal, it is an error, unless the last character is a backslash. This backslash is a special escape which does not denote a character; rather, it indicates that the string literal continues -on the next line. Leading whitespace in the following line is deleted, and -does not constitute part of the string literal, which allows for indentation. +on the next line. The backslash is deleted, along with whitespace which +immediately precedes it, as well as leading whitespace in the following line. The escape sequence "\e " (backslash space) can be used to encode a significant space. +Example: + + "foo \e + bar" + + "foo \e + \ bar" + + "foo\ \e + bar" + +The first string literal is the string "foobar". The second two are "foo bar". + .SS String Quasiliterals Quasiliterals are similar to string literals, except that they may -- cgit v1.2.3