]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
bpo-39648: Expand math.gcd() and math.lcm() to handle multiple arguments. (GH-18604)
authorSerhiy Storchaka <storchaka@gmail.com>
Sun, 23 Feb 2020 11:21:29 +0000 (13:21 +0200)
committerGitHub <noreply@github.com>
Sun, 23 Feb 2020 11:21:29 +0000 (11:21 +0000)
commit559e7f165ad03731e6bc2211c0e6d8d9c02fb549
tree0cf0f31bae98ea188a5fde21a1db4c068539dbdb
parentfbe2e0bb8a7ee75d0f9d57682436dac7d69e202e
bpo-39648: Expand math.gcd() and math.lcm() to handle multiple arguments. (GH-18604)

* bpo-39648: Expand math.gcd() and math.lcm() to handle multiple arguments.

* Simplify fast path.

* Difine lcm() without arguments returning 1.

* Apply suggestions from code review

Co-Authored-By: Mark Dickinson <dickinsm@gmail.com>
Co-authored-by: Mark Dickinson <dickinsm@gmail.com>
Doc/library/math.rst
Doc/whatsnew/3.9.rst
Lib/test/test_math.py
Misc/NEWS.d/next/Library/2020-02-22-12-49-04.bpo-39648.Y-9N7F.rst [new file with mode: 0644]
Modules/clinic/mathmodule.c.h
Modules/mathmodule.c