summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ChangeLog3
-rw-r--r--win/tclWinMtherr.c8
2 files changed, 9 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index d86729c..c69a8c5 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
2001-10-22 Donal K. Fellows <fellowsd@cs.man.ac.uk>
+ * win/tclWinMtherr.c (_matherr): Better handling of selected
+ Borland C++ math errors, from hgiese@ratiosoft.com
+
* generic/tclIndexObj.c (STRING_AT): Fixed so that it builds with
SunPro CC on Solaris, which refuses to perform address arithmetic
on void*, despite the fact that that is necessary to get the
diff --git a/win/tclWinMtherr.c b/win/tclWinMtherr.c
index 7be9b97..6c56f2f 100644
--- a/win/tclWinMtherr.c
+++ b/win/tclWinMtherr.c
@@ -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: tclWinMtherr.c,v 1.3 1999/04/16 00:48:09 stanton Exp $
+ * RCS: @(#) $Id: tclWinMtherr.c,v 1.3.26.1 2001/10/22 14:53:22 dkf Exp $
*/
#include "tclWinInt.h"
@@ -43,7 +43,11 @@ _matherr(xPtr)
if (!TclMathInProgress()) {
return 0;
}
- if ((xPtr->type == DOMAIN) || (xPtr->type == SING)) {
+ if ((xPtr->type == DOMAIN)
+#ifdef __BORLANDC__
+ || (xPtr->type == TLOSS)
+#endif
+ || (xPtr->type == SING)) {
errno = EDOM;
} else {
errno = ERANGE;