bpo-46656: Remove Py_NO_NAN macro (GH-31160)

Building Python now requires support for floating point Not-a-Number
(NaN): remove the Py_NO_NAN macro.
This commit is contained in:
Victor Stinner 2022-02-25 01:32:57 +01:00 committed by GitHub
parent 5f8b5e2f21
commit 1b2611eb02
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
9 changed files with 16 additions and 28 deletions

View file

@ -82,12 +82,10 @@ _Py_parse_inf_or_nan(const char *p, char **endptr)
s += 5;
retval = negate ? -Py_HUGE_VAL : Py_HUGE_VAL;
}
#ifdef Py_NAN
else if (case_insensitive_match(s, "nan")) {
s += 3;
retval = negate ? -Py_NAN : Py_NAN;
}
#endif
else {
s = p;
retval = -1.0;