-
-
Notifications
You must be signed in to change notification settings - Fork 30.5k
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
gh-99767: update PyTypeObject docs for type watchers #99928
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -147,6 +147,8 @@ Quick Reference | |
+------------------------------------------------+-----------------------------------+-------------------+---+---+---+---+ | ||
| :c:member:`~PyTypeObject.tp_vectorcall` | :c:type:`vectorcallfunc` | | | | | | | ||
+------------------------------------------------+-----------------------------------+-------------------+---+---+---+---+ | ||
| :c:member:`~PyTypeObject.tp_watched` | char | | | | | | | ||
+------------------------------------------------+-----------------------------------+-------------------+---+---+---+---+ | ||
|
||
.. [#slots] | ||
|
||
|
@@ -2090,6 +2092,15 @@ and :c:type:`PyType_Type` effectively act as defaults.) | |
.. versionadded:: 3.9 (the field exists since 3.8 but it's only used since 3.9) | ||
|
||
|
||
.. c:member:: char PyTypeObject.tp_watched | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I would rather the docs say "Internal. Do not use." TBH, I would like the whole of the type struct to be "do not use", but let's not make things any worse. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Are you wanting the existing text removed and replaced so it says only "Internal, do not use"? Or do you want to add "Internal, do not use" but also keep the description of what it is? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Pushed a version that removes the existing text, but I can easily re-add it. |
||
|
||
Bitset marking which of the (up to eight) registered :c:func:`type | ||
watchers<PyType_AddWatcher>` are watching this type (via | ||
:c:func:`PyType_Watch`.) | ||
|
||
.. versionadded:: 3.12 | ||
|
||
|
||
.. _static-types: | ||
|
||
Static Types | ||
|
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 this slot is internal, it should be in square brackets like
tp_version_tag
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.
Thanks, sorry I missed this. Added in #100271
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.
Thanks