gh-141510, PEP 814: Add built-in frozendict type#144757
Conversation
Add TYPE_FROZENDICT to the marshal module. Add C API functions: * PyAnyDict_Check() * PyAnyDict_CheckExact() * PyFrozenDict_Check() * PyFrozenDict_CheckExact() * PyFrozenDict_New() Add PyFrozenDict_Type C type.
Fix also indentation.
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
corona10
left a comment
There was a problem hiding this comment.
We should notice that frozendict is not subclass of dict to follow SC feedback
Sorry, something went wrong.
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
Document frozendict after lazy import.
Ah right, done. |
Sorry, something went wrong.
|
🤖 New build scheduled with the buildbot fleet by @corona10 for commit 9101b1a 🤖 Results will be shown at: https://buildbot.python.org/all/#/grid?branch=refs%2Fpull%2F144757%2Fmerge If you want to schedule another build, you need to add the 🔨 test-with-refleak-buildbots label again. |
Sorry, something went wrong.
|
Let's wait build bot to pass the refleak test :) |
Sorry, something went wrong.
benediktjohannes
left a comment
There was a problem hiding this comment.
Nitpick: I know this does not primarily belong to the PR, but it's such a small change that a new PR wouldn't make sense for these small "typos".
Sorry, something went wrong.
Co-authored-by: Adam Johnson <me@adamj.eu>
Tests passed successfully on Refleaks buildbots: |
Sorry, something went wrong.
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
Add also a title in Doc/library/stdtypes.rst.
|
@hugovk: I modified a few more titles in the C API doc and the Python doc to use sentence case for headers. |
Sorry, something went wrong.
corona10
left a comment
There was a problem hiding this comment.
lgtm with current implementations , I will soon create PRs for removing unneeded overhead from my side.
Sorry, something went wrong.
sergey-miryanov
left a comment
There was a problem hiding this comment.
Couple of nitpicks.
Sorry, something went wrong.
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
Co-authored-by: Benedikt Johannes <benedikt.johannes.hofer@gmail.com>
696cdfc
into
python:main
Feb 17, 2026
|
I merged my PR. Thank you very much for all your reviews! |
Sorry, something went wrong.
Add TYPE_FROZENDICT to the marshal module. Add C API functions: * PyAnyDict_Check() * PyAnyDict_CheckExact() * PyFrozenDict_Check() * PyFrozenDict_CheckExact() * PyFrozenDict_New() Add PyFrozenDict_Type C type. Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com> Co-authored-by: Adam Johnson <me@adamj.eu> Co-authored-by: Benedikt Johannes <benedikt.johannes.hofer@gmail.com>
Add TYPE_FROZENDICT to the marshal module. Add C API functions: * PyAnyDict_Check() * PyAnyDict_CheckExact() * PyFrozenDict_Check() * PyFrozenDict_CheckExact() * PyFrozenDict_New() Add PyFrozenDict_Type C type. Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com> Co-authored-by: Adam Johnson <me@adamj.eu> Co-authored-by: Benedikt Johannes <benedikt.johannes.hofer@gmail.com>
Add TYPE_FROZENDICT to the marshal module.
Add C API functions:
Add PyFrozenDict_Type C type.
📚 Documentation preview 📚: https://cpython-previews--144757.org.readthedocs.build/en/144757/c-api/dict.html#frozen-dictionary-objects