]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
bpo-44258: support PEP 515 for Fraction's initialization from string (GH-26422)
authorSergey B Kirpichev <skirpichev@gmail.com>
Mon, 7 Jun 2021 07:06:33 +0000 (10:06 +0300)
committerGitHub <noreply@github.com>
Mon, 7 Jun 2021 07:06:33 +0000 (08:06 +0100)
commit89e50ab36fac6a0e7f1998501f36fcd2872a6604
tree8f708926c1f7f64b60d7da505fd0dbe8e1d2d4a4
parentafb2eed72b32a35b4726ff35f92e4fbf54926046
bpo-44258: support PEP 515 for Fraction's initialization from string (GH-26422)

* bpo-44258: support PEP 515 for Fraction's initialization from string

* regexps's version

* A different regexps version, which doesn't suffer from catastrophic backtracking

* revert denom -> den

* strip "_" from the decimal str, add few tests

* drop redundant tests

* Add versionchanged & whatsnew entry

* Amend Fraction constructor docs

* Change .. versionchanged:...
Doc/library/fractions.rst
Doc/whatsnew/3.11.rst
Lib/fractions.py
Lib/test/test_fractions.py
Misc/NEWS.d/next/Library/2021-05-28-09-43-33.bpo-44258.nh5F7R.rst [new file with mode: 0644]