summaryrefslogtreecommitdiffstats
path: root/generic
diff options
context:
space:
mode:
authordkf <donal.k.fellows@manchester.ac.uk>2004-11-01 14:38:24 (GMT)
committerdkf <donal.k.fellows@manchester.ac.uk>2004-11-01 14:38:24 (GMT)
commit7dbcb9eb54a05922c50c4edd15bac88410020f5c (patch)
tree2652f54557f9dd05985a1dc76023378c310d9823 /generic
parent238f64e8e462d705dbf4f894f4b29933e19e865e (diff)
downloadtcl-7dbcb9eb54a05922c50c4edd15bac88410020f5c.zip
tcl-7dbcb9eb54a05922c50c4edd15bac88410020f5c.tar.gz
tcl-7dbcb9eb54a05922c50c4edd15bac88410020f5c.tar.bz2
Fix for [Bug 761471]; NaN is now *never* equal to NaN...
Diffstat (limited to 'generic')
-rw-r--r--generic/tclExecute.c24
1 files changed, 5 insertions, 19 deletions
diff --git a/generic/tclExecute.c b/generic/tclExecute.c
index b5d24cd..c85f149 100644
--- a/generic/tclExecute.c
+++ b/generic/tclExecute.c
@@ -11,7 +11,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.163 2004/10/28 17:21:23 msofer Exp $
+ * RCS: @(#) $Id: tclExecute.c,v 1.164 2004/11/01 14:38:24 dkf Exp $
*/
#ifdef STDC_HEADERS
@@ -3241,24 +3241,10 @@ TclExecuteByteCode(interp, codePtr)
value2Ptr = *tosPtr;
valuePtr = *(tosPtr - 1);
- if (valuePtr == value2Ptr) {
- /*
- * Optimize the equal object case.
- */
- switch (*pc) {
- case INST_EQ:
- case INST_LE:
- case INST_GE:
- iResult = 1;
- break;
- case INST_NEQ:
- case INST_LT:
- case INST_GT:
- iResult = 0;
- break;
- }
- goto foundResult;
- }
+ /*
+ * Can't optimize the equal-object case; 'NaN' isn't supposed
+ * to be equal to even itself. [Bug 761471]
+ */
t1Ptr = valuePtr->typePtr;
t2Ptr = value2Ptr->typePtr;