| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
|
@tim-one is there an on-going reason to have these portability macros? Are NaN values guaranteed to be supported? |
Sorry, something went wrong.
There was a problem hiding this comment.
LGTM. Simple text replacement.
Sorry, something went wrong.
Python 3.10 and older supported platforms without IEEE 754, without NaN, and without C99 <math.h>. We had complex macros such as: #ifndef Py_IS_NAN
#if defined HAVE_DECL_ISNAN && HAVE_DECL_ISNAN == 1
#define Py_IS_NAN(X) isnan(X)
#else
#define Py_IS_NAN(X) ((X) != (X))
#endif
#endifPython 3.11 and newer requires IEEE 754, NaN and C99 <math.h>. Macros were kept for backward compatibility only: #define Py_IS_NAN(X) isnan(X)Issues:
See also this LWN article: CPython, C standards, and IEEE 754. |
Sorry, something went wrong.
|
@mdickinson: Are you ok with this change? You wrote a comment about these macros there: #119457 (comment) |
Sorry, something went wrong.
Yes, absolutely. I'm fairly sure the macros were born out of (now somewhat ancient) portability needs that no longer apply, now that C99 (and later) adoption is sufficiently widespread. I'd suggest running all buildbots on this PR, just to be on the safe side. |
Sorry, something went wrong.
There was a problem hiding this comment.
LGTM
Sorry, something went wrong.
|
🤖 New build scheduled with the buildbot fleet by @mdickinson for commit 13dcd12 🤖 If you want to schedule another build, you need to add the 🔨 test-with-buildbots label again. |
Sorry, something went wrong.
|
There are tests failures, but hardly it's related to the pr. Something expected, given there are not build bots for non-IEEE-754 platforms, right? |
Sorry, something went wrong.
Agreed - the failures look unrelated. |
Sorry, something went wrong.
|
Merged, thanks. |
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
Uh oh!
There was an error while loading. Please reload this page.
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.