sync abstract.h bindings to Python 3.14#5942
Merged
Conversation
Icxolu
reviewed
Apr 13, 2026
ngoldbaum
reviewed
Apr 14, 2026
Contributor
ngoldbaum
left a comment
There was a problem hiding this comment.
Did a once-over. Claude spotted the type error on the PyVectorcall_NARGS bindings FWIW.
|
|
||
| #[cfg(all(Py_3_12, Py_LIMITED_API))] // is an inline function in cpython/abstract.rs on version-specific ABI | ||
| #[cfg_attr(PyPy, link_name = "PyPyVectorcall_NARGS")] | ||
| pub fn PyVectorcall_NARGS(nargsf: size_t) -> size_t; |
Contributor
There was a problem hiding this comment.
This should return a Py_ssize_t. Does the updated ffi checker also check the return type?
Member
Author
There was a problem hiding this comment.
No sadly in #5965 I don't attempt to reconcile function argument types, just argument count.
(The bindgen code in pyo3-ffi-check creates a completely unrelated definition for PyObject to the one in pyo3-ffi, so "naively" the check legitimately sees different types.)
Member
Author
|
Thanks, fixed the type error and replied to other comments 👍 |
ngoldbaum
approved these changes
Apr 14, 2026
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.
Part of #5592, this is the messiest piece I think.