mirror of
https://github.com/python/cpython.git
synced 2025-10-10 00:43:41 +00:00
Remove checking redundantly for checks of PyInt and PyLong.
This commit is contained in:
parent
538d17aa23
commit
1fe5f38852
7 changed files with 14 additions and 15 deletions
|
@ -331,7 +331,7 @@ float_richcompare(PyObject *v, PyObject *w, int op)
|
|||
j = PyFloat_AS_DOUBLE(w);
|
||||
|
||||
else if (!Py_IS_FINITE(i)) {
|
||||
if (PyInt_Check(w) || PyLong_Check(w))
|
||||
if (PyLong_Check(w))
|
||||
/* If i is an infinity, its magnitude exceeds any
|
||||
* finite integer, so it doesn't matter which int we
|
||||
* compare i with. If i is a NaN, similarly.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue