summaryrefslogtreecommitdiffstats
path: root/tests/parse.test
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2011-05-02 20:10:00 (GMT)
committerdgp <dgp@users.sourceforge.net>2011-05-02 20:10:00 (GMT)
commit9af810992a3d08e5964ca72b8b6221e120fb42d8 (patch)
treea52dbc4a8914a59243eb5871aa40958b6f8f5ccc /tests/parse.test
parent18503cb00a32b1fcb0cb46b7b3649903f38c989a (diff)
downloadtcl-9af810992a3d08e5964ca72b8b6221e120fb42d8.zip
tcl-9af810992a3d08e5964ca72b8b6221e120fb42d8.tar.gz
tcl-9af810992a3d08e5964ca72b8b6221e120fb42d8.tar.bz2
Tests for expanded literals quoting detection.
Diffstat (limited to 'tests/parse.test')
-rw-r--r--tests/parse.test12
1 files changed, 12 insertions, 0 deletions
diff --git a/tests/parse.test b/tests/parse.test
index b5211e7..37c44d5 100644
--- a/tests/parse.test
+++ b/tests/parse.test
@@ -227,6 +227,18 @@ test parse-5.26 {Tcl_ParseCommand: {*} parsing} testparser {
test parse-5.27 {Tcl_ParseCommand: {*} parsing} testparser {
testparser "{*}\\\n foo bar" 0
} {- \{*\}\\\n\ foo\ bar 3 simple {{*}} 1 text * 0 simple foo 1 text foo 0 simple bar 1 text bar 0 {}}
+test parse-5.28 {Tcl_ParseCommand: {*} parsing, expanded literals} testparser {
+ testparser {{*}{a b}} 0
+} {- {{*}{a b}} 2 simple a 1 text a 0 simple b 1 text b 0 {}}
+test parse-5.29 {Tcl_ParseCommand: {*} parsing, expanded literals, naked backslashes} testparser {
+ testparser {{*}{a \n b}} 0
+} {- {{*}{a \n b}} 1 expand {{*}{a \n b}} 1 text {a \n b} 0 {}}
+test parse-5.30 {Tcl_ParseCommand: {*} parsing, expanded literals} testparser {
+ testparser {{*}"a b"} 0
+} {- {{*}"a b"} 2 simple a 1 text a 0 simple b 1 text b 0 {}}
+test parse-5.31 {Tcl_ParseCommand: {*} parsing, expanded literals, naked backslashes} testparser {
+ testparser {{*}"a \n b"} 0
+} {- {{*}"a \n b"} 1 expand {{*}"a \n b"} 3 text {a } 0 backslash {\n} 0 text { b} 0 {}}
test parse-6.1 {ParseTokens procedure, empty word} testparser {
testparser {""} 0