-
-
Notifications
You must be signed in to change notification settings - Fork 31.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
bpo-42747: Remove Py_TPFLAGS_HAVE_AM_SEND and make Py_TPFLAGS_HAVE_VERSION_TAG no-op #27260
bpo-42747: Remove Py_TPFLAGS_HAVE_AM_SEND and make Py_TPFLAGS_HAVE_VERSION_TAG no-op #27260
Conversation
The field is always present in the type struct, as explained in the added comment.
The flag is not needed.
f3ea135
to
7a19100
Compare
How this flag was added and when it was turned into a no-op? |
Py_TPFLAGS_HAVE_* flags have been historically added whenever a new field was added to the type struct, to make it possible to use extensions compiled for earlier Python versions (where the fields aren't present). This PR turns both into no-ops, as they should be. |
@@ -0,0 +1,4 @@ | |||
The ``Py_TPFLAGS_HAVE_VERSION_TAG`` type flag now does nothing. The | |||
``Py_TPFLAGS_HAVE_AM_SEND`` flag (which was added in 3.10) is removed. Both |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Py_TPFLAGS_HAVE_AM_SEND
flag (which was added in 3.10) is removed.
there aren't many users use it?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If there any users of it, they are using the 3.10 betas. Requiring that they remove the flag is fair game.
Thanks @encukou for the PR 🌮🎉.. I'm working now to backport this PR to: 3.10. |
GH-27306 is a backport of this pull request to the 3.10 branch. |
…RSION_TAG no-op (pythonGH-27260) * Remove code that checks Py_TPFLAGS_HAVE_VERSION_TAG The field is always present in the type struct, as explained in the added comment. * Remove Py_TPFLAGS_HAVE_AM_SEND The flag is not needed, and since it was added in 3.10 it can be removed now. (cherry picked from commit a4760cc) Co-authored-by: Petr Viktorin <encukou@gmail.com>
…RSION_TAG no-op (GH-27260) (GH-27306) * Remove code that checks Py_TPFLAGS_HAVE_VERSION_TAG The field is always present in the type struct, as explained in the added comment. * Remove Py_TPFLAGS_HAVE_AM_SEND The flag is not needed, and since it was added in 3.10 it can be removed now. (cherry picked from commit a4760cc) Co-authored-by: Petr Viktorin <encukou@gmail.com>
Thanks for this fix @encukou. The rationale for Py_TPFLAGS_HAVE_AM_SEND was unclear. Now it's well defined, it's useless :-D |
Remove code that checks Py_TPFLAGS_HAVE_VERSION_TAG
The field is always present in the type struct, as explained
in the added comment.
Remove Py_TPFLAGS_HAVE_AM_SEND
The flag is not needed, and since it was added in 3.10 it can be removed now.
https://bugs.python.org/issue42747
Automerge-Triggered-By: GH:encukou