diff options
author | Guido van Rossum <guido@python.org> | 1995-02-13 16:38:41 +0000 |
---|---|---|
committer | Guido van Rossum <guido@python.org> | 1995-02-13 16:38:41 +0000 |
commit | 3e2d4db1b2d79447f0a3a0d1dc6bebcb37608e69 (patch) | |
tree | 6043c6b4819adb4f4e2bb1592af38c65d0eba8ae /Objects | |
parent | 75f22df1918b2544420b9d473c02894c55473da4 (diff) | |
download | cpython-3e2d4db1b2d79447f0a3a0d1dc6bebcb37608e69.tar.gz |
NeXT/Sparc 3.3 fix
Diffstat (limited to 'Objects')
-rw-r--r-- | Objects/floatobject.c | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/Objects/floatobject.c b/Objects/floatobject.c index 60dcca9529..04d80b165f 100644 --- a/Objects/floatobject.c +++ b/Objects/floatobject.c @@ -59,6 +59,18 @@ OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. #define LONG_MIN (-LONG_MAX-1) #endif +#ifdef __NeXT__ +#ifdef __sparc__ +/* + * This works around a bug in the NS/Sparc 3.3 pre-release + * limits.h header file. + * 10-Feb-1995 bwarsaw@cnri.reston.va.us + */ +#undef LONG_MIN +#define LONG_MIN (-LONG_MAX-1) +#endif +#endif + #ifndef __STDC__ extern double fmod PROTO((double, double)); extern double pow PROTO((double, double)); @@ -406,7 +418,7 @@ float_int(v) double x = getfloatvalue(v); if (x < 0 ? (x = ceil(x)) < (double)LONG_MIN : (x = floor(x)) > (double)LONG_MAX) { - err_setstr(OverflowError, "float to large to convert"); + err_setstr(OverflowError, "float too large to convert"); return NULL; } return newintobject((long)x); |