diff options
author | Steve Bennett <steveb@workware.net.au> | 2011-05-31 09:59:10 +1000 |
---|---|---|
committer | Steve Bennett <steveb@workware.net.au> | 2011-05-31 09:59:10 +1000 |
commit | 4677ec429de974a4b91a22711af48df366a224b9 (patch) | |
tree | c4cb3a61dfefec976957f3d68d9594d63332799a /tests | |
parent | 8f25329ef23f53aa252d32b1fcc78eb426978351 (diff) | |
download | jimtcl-4677ec429de974a4b91a22711af48df366a224b9.zip jimtcl-4677ec429de974a4b91a22711af48df366a224b9.tar.gz jimtcl-4677ec429de974a4b91a22711af48df366a224b9.tar.bz2 |
Fix a minor parsing bug - quoted backslash newline
Should eat spaces and tabs after the newline
Signed-off-by: Steve Bennett <steveb@workware.net.au>
Diffstat (limited to 'tests')
-rw-r--r-- | tests/parse.test | 27 |
1 files changed, 26 insertions, 1 deletions
diff --git a/tests/parse.test b/tests/parse.test index 8422c51..870d4ff 100644 --- a/tests/parse.test +++ b/tests/parse.test @@ -227,8 +227,33 @@ test parse-1.45 "spaces before expr function args" { expr {round (3.2)} } 3 -test parse-1.45 "expr function missing paren" { +test parse-1.46 "expr function missing paren" { catch {expr {round 3.2}} } 1 +test parse-1.47 "backslash newline in quotes" { + # spaces + set x "abc\ + def" +} "abc def" + +test parse-1.48 "backslash newline in quotes" { + # tabs + set x "abc\ + def" +} "abc def" + +test parse-1.49 "backslash newline in quotes" { + # tabs plus newline + set x "abc\ + +def" +} "abc \ndef" + +test parse-1.50 "backslash newline in quotes" { + # tabs plus newline + set x "abc\ +def" +} "abc def" + testreport |