From 2022ffbe107b1d314df5ef2b4191975d8c263c8f Mon Sep 17 00:00:00 2001 From: dgp Date: Tue, 4 Mar 2008 18:50:01 +0000 Subject: * tests/execute.test (6.3,4): Added tests for Bug 1899164]. --- ChangeLog | 4 ++++ tests/execute.test | 20 +++++++++++++++++++- 2 files changed, 23 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index e93d091..6b000e2 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2008-03-04 Don Porter + + * tests/execute.test (6.3,4): Added tests for Bug 1899164]. + 2008-03-03 Reinhard Max * unix/tclUnixChan.c: Fix mark and space parity on Linux, which diff --git a/tests/execute.test b/tests/execute.test index bc54725..7c4545d 100644 --- a/tests/execute.test +++ b/tests/execute.test @@ -14,7 +14,7 @@ # See the file "license.terms" for information on usage and redistribution # of this file, and for a DISCLAIMER OF ALL WARRANTIES. # -# RCS: @(#) $Id: execute.test,v 1.24 2006/11/03 00:34:52 hobbs Exp $ +# RCS: @(#) $Id: execute.test,v 1.25 2008/03/04 18:50:04 dgp Exp $ if {[lsearch [namespace children] ::tcltest] == -1} { package require tcltest 2 @@ -590,6 +590,24 @@ test execute-6.2 {Evaluate an expression in a variable; compile the first time, proc a {obj} {expr $obj} set res "[a $w]:[a $w]" } {15:15} +test execute-6.3 {Tcl_ExprObj: don't use cached script bytecode [Bug 1899164]} -setup { + proc 0+0 {} {return SCRIPT} +} -body { + set e { 0+0 } + if 1 $e + if 1 {expr $e} +} -cleanup { + rename 0+0 {} +} -result 0 +test execute-6.4 {TclCompEvalObj: don't use cached expr bytecode [Bug 1899164]} -setup { + proc 0+0 {} {return SCRIPT} +} -body { + set e { 0+0 } + if 1 {expr $e} + if 1 $e +} -cleanup { + rename 0+0 {} +} -result SCRIPT test execute-7.0 {Wide int handling in INST_JUMP_FALSE/LAND} { set x 0x100000000 -- cgit v0.12