Roumen Petrov <[email protected]> added the comment: I'm not sure that patch has to deal with "force to memory". FYI: when I port python trunk to mingw platform I encounter some inconsistency for isinf.
My note about issue follow: - configure.in: ... dnl FIXME: For mingw "isinf" is a macro defined in <math.h> and can't be dnl detected as function. Also PC/pyconfig.h define HAVE_ISINF but it is dnl useless since header define Py_IS_INFINITY as (!_finite(X) && !_isnan(X)) dnl Also in pymath.h is commented too how PC/pyconfig.h define _isinf. dnl NOTE: For mingw to keep compatibility with native build we define dnl Py_IS_INFINITY in pyport.h. ... - pyport.h #ifdef __MINGW32__ ... /*NOTE: mingw has isinf as macro defined in math.h. Since PC/pyconfig.h define Py_IS_INFINITY(X) that cover HAVE_ISINF here for Py_IS_INFINITY we define same as for native build. This makes HAVE_ISINF needless. Also see comments in configure.in and pymath.h. */ #define Py_IS_INFINITY(X) (!_finite(X) && !_isnan(X)) .... next lest see Py_IS_INFINITY in pymath.h .... #ifndef Py_IS_INFINITY #ifdef HAVE_ISINF #define Py_IS_INFINITY(X) isinf(X) #else #define Py_IS_INFINITY(X) ((X) && (X)*0.5 == (X)) #endif #endif .... Is the macro Py_IS_INFINITY correct if isinf is not detected by configure script ? Also I think too that problem is that we has to classify result after conversion to double. _______________________________________ Python tracker <[email protected]> <http://bugs.python.org/issue4575> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
