◐ Shell
clean mode source ↗

gh-90716: bugfixes and more tests for _pylong. by gpshead · Pull Request #99073 · python/cpython

* Properly decref on _pylong import error.
* Improve the error message on _pylong TypeError.
* Tie the return value comments together.

These are minor followups to issues not caught among the reviewers on
python#96673.

@bedevere-bot mentioned this pull request

Nov 3, 2022

@gpshead gpshead marked this pull request as ready for review

November 3, 2022 19:22

gpshead referenced this pull request

Nov 3, 2022
Add Python implementations of certain longobject.c functions. These use
asymptotically faster algorithms that can be used for operations on
integers with many digits. In those cases, the performance overhead of
the Python implementation is not significant since the asymptotic
behavior is what dominates runtime. Functions provided by this module
should be considered private and not part of any public API.

Co-author: Tim Peters <tim.peters@gmail.com>
Co-author: Mark Dickinson <dickinsm@gmail.com>
Co-author: Bjorn Martinsson
As they covers cpython internal details.

nascheme

by adding the same check and TypeError on the to_decimal_string side.

@gpshead gpshead deleted the _pylong_pr_followup_fixes branch

November 3, 2022 23:18