diff options
author | Miguel Sofer <miguel.sofer@gmail.com> | 2008-08-13 22:02:27 (GMT) |
---|---|---|
committer | Miguel Sofer <miguel.sofer@gmail.com> | 2008-08-13 22:02:27 (GMT) |
commit | d0122a5130593dd68e1d2ebcda75380f031156d7 (patch) | |
tree | be137cbe6f7b03619a6b699f4423a4f7c227fc71 | |
parent | fce0abd807701f8f0b1cbc8f820d3254efdd7f32 (diff) | |
download | tcl-d0122a5130593dd68e1d2ebcda75380f031156d7.zip tcl-d0122a5130593dd68e1d2ebcda75380f031156d7.tar.gz tcl-d0122a5130593dd68e1d2ebcda75380f031156d7.tar.bz2 |
* tests/nre.test: added test for large {*}-expansion effects
-rw-r--r-- | ChangeLog | 4 | ||||
-rw-r--r-- | tests/nre.test | 18 |
2 files changed, 21 insertions, 1 deletions
@@ -1,3 +1,7 @@ +2008-08-13 Miguel Sofer <msofer@users.sf.net> + + * tests/nre.test: added test for large {*}-expansion effects + 2008-08-13 Don Porter <dgp@users.sourceforge.net> * generic/tclFileName.c: Fix for errors handling -types {} diff --git a/tests/nre.test b/tests/nre.test index 28861de..8e98991 100644 --- a/tests/nre.test +++ b/tests/nre.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: nre.test,v 1.2 2008/08/04 15:32:40 msofer Exp $ +# RCS: @(#) $Id: nre.test,v 1.3 2008/08/13 22:02:27 msofer Exp $ if {[lsearch [namespace children] ::tcltest] == -1} { package require tcltest @@ -236,6 +236,22 @@ test nre-7.5 {[foreach] is not recursive} -constraints {knownbug} -setup { unset abs } -result {{0 2 2 0} 0} +test nre-8.1 {nre and {*}} -body { + # force an expansion that grows the evaluation stack, check that nre + # adapts the bottomPtr. This crashes on failure. + + proc inner {} { + set long [lrepeat 1000000 1] + list {*}$long + } + proc outer {} inner + lrange [outer] 0 2 +} -cleanup { + rename inner {} + rename outer {} +} -result {1 1 1} + + # # Basic TclOO tests # |