diff options
Diffstat (limited to 'tests')
-rw-r--r-- | tests/execute.test | 20 |
1 files changed, 19 insertions, 1 deletions
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 |