{{ message }}
bpo-40170: Convert PyIter_Check macro to a function - #24548
Merged
Merged
Conversation
Contributor
Author
erlend-aasland
force-pushed
the
bpo-40170/PyIter_Check
branch
from
February 16, 2021 10:05
ec6687a to
7c03394
Compare
vstinner
reviewed
Feb 16, 2021
vstinner
left a comment
Member
There was a problem hiding this comment.
For macOS which doesn't use LTO compiler optimization, we added private static inline functions of some "Check" functions. But I don't think that it's worth it here (I don't think that the function is commonly called in "hot code").
Co-authored-by: Victor Stinner <vstinner@python.org>
Co-authored-by: Victor Stinner <vstinner@python.org>
Contributor
Author
|
CI is done; PTAL, @vstinner. |
Member
|
Merged, thanks. |
erlend-aasland
pushed a commit
to erlend-aasland/cpython
that referenced
this pull request
Feb 17, 2021
…to "C API" section
adorilson
pushed a commit
to adorilson/cpython
that referenced
this pull request
Mar 13, 2021
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

The macro accessed the
PyTypeObject.tp_iternextmember directly."Swap" macro variant with the function in order to hide implementation details.
(A function already existed, but it was not exposed.)
https://bugs.python.org/issue40170