From 5a6b65068cccb6e5109ddd85bd447bffbbf2f335 Mon Sep 17 00:00:00 2001 From: Miguel Sofer Date: Sat, 14 Apr 2007 17:35:53 +0000 Subject: * generic/tclExecute.c: removed some code at INSTEXPAND_SKTOP that duplicates functionality already present at checkForCatch. --- ChangeLog | 5 +++++ generic/tclExecute.c | 14 ++++++-------- 2 files changed, 11 insertions(+), 8 deletions(-) diff --git a/ChangeLog b/ChangeLog index 14f6408..249a03e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2007-04-14 Miguel Sofer + + * generic/tclExecute.c: removed some code at INSTEXPAND_SKTOP that + duplicates functionality already present at checkForCatch. + 2007-04-12 Miguel Sofer * generic/tclExecute.c: new macros OBJ_AT_TOS, OBJ_UNDER_TOS, diff --git a/generic/tclExecute.c b/generic/tclExecute.c index b296e5c..4ef4d04 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.275 2007/04/11 17:55:46 msofer Exp $ + * RCS: @(#) $Id: tclExecute.c,v 1.276 2007/04/14 17:35:54 msofer Exp $ */ #include "tclInt.h" @@ -1671,21 +1671,19 @@ TclExecuteByteCode( case INST_EXPAND_STKTOP: { int objc, length, i; - Tcl_Obj **objv, *valuePtr, *objPtr; + Tcl_Obj **objv, *valuePtr; /* - * Make sure that the element at stackTop is a list; if not, remove - * the element from the expand link list and leave. + * Make sure that the element at stackTop is a list; if not, just + * leave with an error. Note that the element from the expand list + * will be removed at checkForCatch. */ valuePtr = OBJ_AT_TOS; if (Tcl_ListObjGetElements(interp, valuePtr, &objc, &objv) != TCL_OK) { - result = TCL_ERROR; TRACE_WITH_OBJ(("%.30s => ERROR: ", O2S(valuePtr)), Tcl_GetObjResult(interp)); - objPtr = expandNestList; - expandNestList = (Tcl_Obj *) objPtr->internalRep.twoPtrValue.ptr2; - TclDecrRefCount(objPtr); + result = TCL_ERROR; goto checkForCatch; } POP_OBJECT(); -- cgit v0.12