summaryrefslogtreecommitdiffstats
path: root/generic/tclExecute.c
diff options
context:
space:
mode:
authorMiguel Sofer <miguel.sofer@gmail.com>2005-10-10 17:59:37 (GMT)
committerMiguel Sofer <miguel.sofer@gmail.com>2005-10-10 17:59:37 (GMT)
commit876e0a64558dd715ec43f41dbc8ae7c7438e96ed (patch)
tree2875131a5be0128fca9ed2b6d414b8295dd37fee /generic/tclExecute.c
parent2e093041b6542fddc7628829bea7e3ce6aad2bbd (diff)
downloadtcl-msofer_wcodes_branch.zip
tcl-msofer_wcodes_branch.tar.gz
tcl-msofer_wcodes_branch.tar.bz2
* generic/tclExecute.c: fixing an error in INST_LNOT and msofer_wcodes_branch
INST_LYES. Interestingly, the error only appeared in debug builds, but I can't figure out how it matters. * generic/tclCompile.c (OptReduceCount): improved panic message. *** NOTE: disabling the optimiser causes a panic in normal builds, but is ok in debug builds. Something is very fishy.
Diffstat (limited to 'generic/tclExecute.c')
-rw-r--r--generic/tclExecute.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/generic/tclExecute.c b/generic/tclExecute.c
index 2864945..2f1fade 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.171.2.30 2005/06/13 01:46:05 msofer Exp $
+ * RCS: @(#) $Id: tclExecute.c,v 1.171.2.31 2005/10/10 17:59:38 msofer Exp $
*/
#include "tclInt.h"
@@ -860,7 +860,9 @@ Tcl_ExprObj(interp, objPtr, resultPtrPtr)
TclEmitInst0(INST_DONE, &compEnv);
TclInitByteCodeObj(objPtr, &compEnv);
+#if VM_ENABLE_OPTIMISER
TclOptimiseByteCode (interp, objPtr);
+#endif
TclFreeCompileEnv(&compEnv);
codePtr = (ByteCode *) objPtr->internalRep.otherValuePtr;
#ifdef TCL_COMPILE_DEBUG
@@ -4049,7 +4051,7 @@ TclExecuteByteCode(interp, codePtr)
NEXT_INST_F(0, 0);
}
} else { /* inst is INST_LNOT or INST_LYES*/
- if (tPtr == &tclIntType) {
+ if ((tPtr == &tclIntType) || (tPtr == &tclBooleanType)){
i = valuePtr->internalRep.longValue;
TRACE_WITH_OBJ(("%ld => ", i), objResultPtr);
} else if (tPtr == &tclWideIntType) {