diff options
author | stanton <stanton> | 1998-09-21 23:39:52 (GMT) |
---|---|---|
committer | stanton <stanton> | 1998-09-21 23:39:52 (GMT) |
commit | 494c2de3a748b449c69ce322a1a741f5a31fd4d5 (patch) | |
tree | c3ece48c0ae3f4ba54787e0e8e729b65752ef3f9 /tests/var.test | |
parent | 7a698c0488d99c0af42022714638ae1ba2afaa49 (diff) | |
download | tcl-494c2de3a748b449c69ce322a1a741f5a31fd4d5.zip tcl-494c2de3a748b449c69ce322a1a741f5a31fd4d5.tar.gz tcl-494c2de3a748b449c69ce322a1a741f5a31fd4d5.tar.bz2 |
Added contents of Tcl 8.1a2
Diffstat (limited to 'tests/var.test')
-rw-r--r-- | tests/var.test | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/tests/var.test b/tests/var.test index 6452577..9c10ed7 100644 --- a/tests/var.test +++ b/tests/var.test @@ -13,7 +13,7 @@ # See the file "license.terms" for information on usage and redistribution # of this file, and for a DISCLAIMER OF ALL WARRANTIES. # -# SCCS: @(#) var.test 1.10 97/07/28 18:31:47 +# SCCS: @(#) var.test 1.12 98/02/05 20:22:48 # if {[string compare test [info procs test]] == 1} then {source defs} @@ -27,7 +27,7 @@ catch {unset i} catch {unset a} catch {unset arr} -test var-1.1 {TclLookupVar, TCL_PARSE_PART1 flag set} { +test var-1.1 {TclLookupVar, Array handling} { catch {unset a} set x "incr" ;# force no compilation and runtime call to Tcl_IncrCmd set i 10 @@ -450,6 +450,11 @@ test var-9.9 {behaviour of TclSetVar without TCL_LEAVE_ERR_MSG flag} { list [catch {testsetnoerr v 2} msg] $msg } {1 {before set}} +test var-10.1 {can't nest arrays with array set} { + catch {unset arr} + list [catch {array set arr(x) {a 1 b 2}} res] $res +} {1 {can't set "arr(x)(a)": variable isn't array}} + catch {namespace delete ns} catch {unset arr} catch {unset v} @@ -465,3 +470,4 @@ catch {unset a} catch {unset xxxxx} catch {unset aaaaa} +return |