Visitar URL original
bpo-32891: rename numbers.Integral to numbers.Integer by skirpichev · Pull Request #25552 · python/cpython · GitHub
The Wayback Machine - https://web.archive.org/web/20250622140953/https://github.com/python/cpython/pull/25552
Skip to content

bpo-32891: rename numbers.Integral to numbers.Integer #25552

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 5 commits into from
Closed

bpo-32891: rename numbers.Integral to numbers.Integer #25552

wants to merge 5 commits into from

Conversation

skirpichev
Copy link
Contributor

@skirpichev skirpichev commented Apr 23, 2021 •

I'm not sure how to reproduce pickle problem, mentioned by Serhiy in the issue thread. Seems to be working...

There are few things that might be changed too, but I'm not sure they are suitable for this pr:

  1. pymath.h's macroses (e.g. _Py_InIntegralTypeRange -> _Py_InIntegerTypeRange)
  2. Few Decimal's methods (e.g. to_integral() -> to_integer())

https://bugs.python.org/issue32891

@skirpichev
Copy link
Contributor Author

@terryjreedy, I would appreciate your review, as issue creator. The patch itself is tiny (Lib/numbers.py, Doc/library/numbers.rst and few places where the new class is referenced, instead of the old). The rest is my attempt to make docs more consistent in using integer vs integral. I can split that part to a separate commit, if this simplify review somehow.

BTW, PEP 3141 references the old naming scheme. Perhaps, it must be updated?

@rhettinger rhettinger removed their request for review April 24, 2021 00:36
@skirpichev
Copy link
Contributor Author

skirpichev commented Apr 26, 2021 via email

@mdickinson
Copy link
Member

Python comments invent a new noun, integral

That would also be wrong, but in all the cases I've seen in comments and documentation, "integral" is being used as an adjective, not a noun. Do you have counterexamples?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants