diff options
author | dgp <dgp@users.sourceforge.net> | 2006-03-08 16:07:42 (GMT) |
---|---|---|
committer | dgp <dgp@users.sourceforge.net> | 2006-03-08 16:07:42 (GMT) |
commit | 9dcbe336bddd91bb7fab7be8e33ce7fed7f229ce (patch) | |
tree | a3b89f3d8743fcc549b1179e0277156166206aff | |
parent | 989e6a53bd54006ab5d9e15bb79f67fa2e7ece22 (diff) | |
download | tcl-9dcbe336bddd91bb7fab7be8e33ce7fed7f229ce.zip tcl-9dcbe336bddd91bb7fab7be8e33ce7fed7f229ce.tar.gz tcl-9dcbe336bddd91bb7fab7be8e33ce7fed7f229ce.tar.bz2 |
* generic/tclExecute.c: Complete missing bit of TIP 215 implementation
* tests/incr.test:
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | generic/tclExecute.c | 4 | ||||
-rw-r--r-- | tests/incr.test | 9 |
3 files changed, 15 insertions, 3 deletions
@@ -1,3 +1,8 @@ +2006-03-08 Don Porter <dgp@users.sourceforge.net> + + * generic/tclExecute.c: Complete missing bit of TIP 215 implementation + * tests/incr.test: + 2006-03-07 Joe English <jenglish@users.sourceforge.net> * unix/tcl.m4: Set SHLIB_LD_FLAGS='${LIBS}' on NetBSD, as per the other *BSD variants [Bug 1334613]. diff --git a/generic/tclExecute.c b/generic/tclExecute.c index 6777cd2..bdd106c 100644 --- a/generic/tclExecute.c +++ b/generic/tclExecute.c @@ -12,7 +12,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclExecute.c,v 1.226 2006/02/09 17:34:41 dgp Exp $ + * RCS: @(#) $Id: tclExecute.c,v 1.227 2006/03/08 16:07:42 dgp Exp $ */ #include "tclInt.h" @@ -2431,7 +2431,7 @@ TclExecuteByteCode( } TRACE(("%u \"%.30s\" (by %ld) => ", opnd, part2, i)); varPtr = TclLookupArrayElement(interp, part1, part2, - TCL_LEAVE_ERR_MSG, "read", 0, 1, arrayPtr); + TCL_LEAVE_ERR_MSG, "read", 1, 1, arrayPtr); if (varPtr == NULL) { TRACE_APPEND(("ERROR: %.30s\n", O2S(Tcl_GetObjResult(interp)))); result = TCL_ERROR; diff --git a/tests/incr.test b/tests/incr.test index 3bd1541..9ac1443 100644 --- a/tests/incr.test +++ b/tests/incr.test @@ -10,7 +10,7 @@ # See the file "license.terms" for information on usage and redistribution # of this file, and for a DISCLAIMER OF ALL WARRANTIES. # -# RCS: @(#) $Id: incr.test,v 1.12 2006/02/09 17:34:42 dgp Exp $ +# RCS: @(#) $Id: incr.test,v 1.13 2006/03/08 16:07:43 dgp Exp $ if {[lsearch [namespace children] ::tcltest] == -1} { package require tcltest 2 @@ -514,6 +514,13 @@ test incr-3.2 {increment by wide amount: command route} { $z x 123123123123 } 123123123123 +test incr-4.1 {increment non-existing array element [Bug 1445454]} -body { + proc x {} {incr a(1)} + x +} -cleanup { + rename x {} +} -result 1 + # cleanup ::tcltest::cleanupTests return |