From 3afb272f26e300ebb6819900aa5ac93333f7bf58 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Mon, 3 Sep 2018 13:15:22 +0200 Subject: Update to match new pre-formatter fragment escape semantics in CLI --- doc/testscript.cli | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/doc/testscript.cli b/doc/testscript.cli index b7e89f1..deeba89 100644 --- a/doc/testscript.cli +++ b/doc/testscript.cli @@ -1156,7 +1156,7 @@ escaped with a backslash (\c{\\}) to preserve their literal meaning (to specify literal backslash you need to escape it as well). For example: \ -foo = \$foo\\bar # '$foo\bar' +foo = \$foo\\\\bar # '$foo\bar' \ Note that quoting could often be a more readable way to achieve the same @@ -1295,7 +1295,7 @@ echo $args # echo foo To preserve quotes in this context we need to escape them: \ -args = \"\\'foo\\'\" # \'foo\' +args = \"\\\\'foo\\\\'\" # \'foo\' echo $args # echo 'foo' \ @@ -1729,7 +1729,7 @@ semantics is the same as in \c{scope-if}. For example: \ if ($cxx.target.class == 'windows') - slash = \\ + slash = \\\\ case = false else slash = / @@ -1741,7 +1741,7 @@ When conditionally setting a single variable, using the evaluation context with a ternary operator is often more concise: \ -slash = ($cxx.target.class == 'windows' ? \\ : /) +slash = ($cxx.target.class == 'windows' ? \\\\ : /) \ Note also that the only purpose of having a separate (from \c{command-if}) @@ -2596,7 +2596,7 @@ are supported. \U - Convert next characters until \E to the upper case. \L - Convert next characters until \E to the lower case. - \\ - Literal backslash. + \\\\ - Literal backslash. \ Note that unlike POSIX semantics, just \c{&} does not have a special meaning -- cgit v1.1