summaryrefslogtreecommitdiffstats
path: root/tests/namespace-old.test
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2020-10-30 13:27:52 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2020-10-30 13:27:52 (GMT)
commit076a7e2839881c03d0a98a8fc50823aef42ad79a (patch)
tree26698b0ef5c437526bbf0b1f88222dd4a0275d2a /tests/namespace-old.test
parent9efaa4d7f1aeb58c52fe41c62713b568a0833948 (diff)
downloadtcl-076a7e2839881c03d0a98a8fc50823aef42ad79a.zip
tcl-076a7e2839881c03d0a98a8fc50823aef42ad79a.tar.gz
tcl-076a7e2839881c03d0a98a8fc50823aef42ad79a.tar.bz2
Add "{}" around many "expr" commands in testcases. Also in doc/expr.n
Diffstat (limited to 'tests/namespace-old.test')
-rw-r--r--tests/namespace-old.test4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/namespace-old.test b/tests/namespace-old.test
index 1d6a805..e4715f8 100644
--- a/tests/namespace-old.test
+++ b/tests/namespace-old.test
@@ -749,13 +749,13 @@ test namespace-old-9.14 {imported commands can be removed} {
} {{} 1 {invalid command name "cmd1"}}
test namespace-old-9.15 {existing commands can't be overwritten} {
proc cmd1 {x y} {
- return [expr $x+$y]
+ return [expr {$x+$y}]
}
list [catch {namespace import test_ns_import::cmd?} msg] $msg \
[cmd1 3 5]
} {1 {can't import command "cmd1": already exists} 8}
test namespace-old-9.16 {use "-force" option to override existing commands} {
- proc cmd1 {x y} { return [expr $x+$y] }
+ proc cmd1 {x y} { return [expr {$x+$y}] }
list [cmd1 3 5] \
[namespace import -force test_ns_import::cmd?] \
[cmd1 3 5]