diff options
author | hobbs <hobbs> | 2001-09-11 18:26:27 (GMT) |
---|---|---|
committer | hobbs <hobbs> | 2001-09-11 18:26:27 (GMT) |
commit | ee5192e7df744668001d9976560faa2de885e014 (patch) | |
tree | 426a50c165bd410e21f127543520813f02772fbb /tests | |
parent | 1647ff8d9dd37952c9057ec191af3f33ec595b8e (diff) | |
download | tcl-ee5192e7df744668001d9976560faa2de885e014.zip tcl-ee5192e7df744668001d9976560faa2de885e014.tar.gz tcl-ee5192e7df744668001d9976560faa2de885e014.tar.bz2 |
reworked stack-2.1 to be impervious to interp state
Diffstat (limited to 'tests')
-rw-r--r-- | tests/stack.test | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/tests/stack.test b/tests/stack.test index 1d1bdce..fef667e 100644 --- a/tests/stack.test +++ b/tests/stack.test @@ -9,7 +9,7 @@ # See the file "license.terms" for information on usage and redistribution # of this file, and for a DISCLAIMER OF ALL WARRANTIES. # -# RCS: @(#) $Id: stack.test,v 1.10 2001/09/11 00:46:35 hobbs Exp $ +# RCS: @(#) $Id: stack.test,v 1.11 2001/09/11 18:26:27 hobbs Exp $ if {[lsearch [namespace children] ::tcltest] == -1} { package require tcltest @@ -46,10 +46,12 @@ test stack-1.1 {maxNestingDepth reached on infinite recursion} {minStack2400} { } {too many nested calls to Tcl_EvalObj (infinite loop?)} test stack-2.1 {maxNestingDepth reached on infinite recursion} {minStack2400} { - catch {rename unknown unknown_safe} - interp alias {} unknown {} notaknownproc - catch {foo} msg - catch {rename unknown {} ; rename unknown_safe unknown} + # do this in a slave to not mess with parent + set slave stack-2.1 + interp create $slave + $slave eval { interp alias {} unknown {} notaknownproc } + set msg [$slave eval { catch {foo} msg ; set msg }] + interp delete $slave set msg } {too many nested calls to AliasObjCmd (infinite loop using alias?)} |