Skip to content

[3.10] bpo-42161: mathmodule.c: move _PyLong_GetOne() loop invariant (GH-26391) - #26393

Merged
vstinner merged 1 commit into
python:3.10from
miss-islington:backport-3e7ee02-3.10
May 26, 2021
Merged

vstinner merged 1 commit into
python:3.10from
miss-islington:backport-3e7ee02-3.10

Conversation

@miss-islington

@miss-islington miss-islington commented May 26, 2021 •

Copy link
Copy Markdown
Contributor

Move _PyLong_GetZero() and _PyLong_GetOne() loop invariants outside
loops in functions:

  • math.comb()
  • math.gcd()
  • math.lcm()
  • math.perm()
    (cherry picked from commit 3e7ee02)

Co-authored-by: Victor Stinner vstinner@python.org

https://bugs.python.org/issue42161

…GH-26391)

Move _PyLong_GetZero() and _PyLong_GetOne() loop invariants outside
loops in functions:

* math.comb()
* math.gcd()
* math.lcm()
* math.perm()
(cherry picked from commit 3e7ee02)

Co-authored-by: Victor Stinner <vstinner@python.org>
@miss-islington

Copy link
Copy Markdown
Contributor Author

@vstinner: Status check is done, and it's a success ✅ .

@miss-islington

Copy link
Copy Markdown
Contributor Author

@vstinner: Status check is done, and it's a success ✅ .

@vstinner vstinner left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, good bot.

@vstinner
vstinner merged commit 4115996 into python:3.10 May 26, 2021
@miss-islington
miss-islington deleted the backport-3e7ee02-3.10 branch May 26, 2021 23:13
@miss-islington

Copy link
Copy Markdown
Contributor Author

@vstinner: Status check is done, and it's a success ❌ .

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

4 participants