Skip to content

Add new dictionary functions and extern declarations#5947

Merged
Tpt merged 26 commits intoPyO3:mainfrom
clin1234:patch-2
Apr 17, 2026
Merged

Add new dictionary functions and extern declarations#5947
Tpt merged 26 commits intoPyO3:mainfrom
clin1234:patch-2

Conversation

@clin1234
Copy link
Copy Markdown
Contributor

@clin1234 clin1234 commented Apr 4, 2026

Added new functions for dictionary operations and updated extern declarations.

Copy link
Copy Markdown
Contributor

@Tpt Tpt left a comment

Choose a reason for hiding this comment

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

Thank you!

@Tpt Tpt added this pull request to the merge queue Apr 4, 2026
@Tpt Tpt removed this pull request from the merge queue due to a manual request Apr 4, 2026
Comment thread pyo3-ffi/src/cpython/dictobject.rs
@Tpt Tpt self-requested a review April 4, 2026 13:31
@clin1234
Copy link
Copy Markdown
Contributor Author

@Tpt and @davidhewitt, mind reviewing this and #5949 again?

Comment thread pyo3-ffi/src/dictobject.rs Outdated
Comment thread pyo3-ffi/src/cpython/dictobject.rs
Comment thread pyo3-ffi/src/dictobject.rs Outdated
Comment thread pyo3-ffi/src/dictobject.rs Outdated
Comment thread pyo3-ffi/src/cpython/dictobject.rs
Co-authored-by: Thomas Tanon <thomas@pellissier-tanon.fr>
@Tpt Tpt enabled auto-merge April 17, 2026 16:13
auto-merge was automatically disabled April 17, 2026 17:09

Head branch was pushed to by a user without write access

@Tpt Tpt enabled auto-merge April 17, 2026 17:23
@Tpt Tpt added this pull request to the merge queue Apr 17, 2026
@github-merge-queue github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Apr 17, 2026
@Tpt Tpt added this pull request to the merge queue Apr 17, 2026
Merged via the queue into PyO3:main with commit 999560a Apr 17, 2026
44 of 45 checks passed
davidhewitt pushed a commit to davidhewitt/pyo3 that referenced this pull request May 1, 2026
* Add new dictionary functions and extern declarations

Added new functions for dictionary operations and updated extern declarations.

* Add PyDict_SetDefaultRef function declaration

* Create 5947.added.md

* Fix syntax errors in dictobject.rs configuration flags

* Reorder imports in dictobject.rs

* Update PyDict_SetDefaultRef and PyDict_Pop signatures

* Fix pointer type in PyDict_SetDefaultRef function

* Fmt

* Fix conditional compilation directive for PyDict_SetDefaultRef

* Update conditional compilation for PyDict_SetDefaultRef

* Change key parameter type from char to c_char

* Update imports for Python version compatibility

Conditionally include c_char and c_int based on Python version.

* Fix typo in import statement for c_int

* Reintroduce PyDict_SetDefaultRef for Python 3.15

* Fix cfg attribute syntax in dictobject.rs

* Reorganize use statements in dictobject.rs

* Remove PyObject_GenericGetDict declaration

Removed PyObject_GenericGetDict function declaration for non-limited API.

* Remove unused c_void import in dictobject.rs

Removed unused import of c_void for non-limited API.

* Update PyDict_SetDefaultRef for Python 3.13 compatibility

* Comment out PyDict_SetDefaultRef function

Comment out the PyDict_SetDefaultRef function definition for specific Python versions.

* Member naming

Co-authored-by: Thomas Tanon <thomas@pellissier-tanon.fr>

* Mark function as part of Stable API as of 3.15

Co-authored-by: Thomas Tanon <thomas@pellissier-tanon.fr>

* Reorder dictobject.rs  to mirror upstream C header

* Space

* Add GraalPy conditional compilation for dict functions

---------

Co-authored-by: Thomas Tanon <thomas@pellissier-tanon.fr>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants