https://github.com/python/cpython/commit/e1220814321bd0bc773f094ca0c72b8cf00f5dbf commit: e1220814321bd0bc773f094ca0c72b8cf00f5dbf branch: 3.12 author: Miss Islington (bot) <[email protected]> committer: serhiy-storchaka <[email protected]> date: 2024-01-24T20:05:24Z summary:
[3.12] gh-108731: Add description of __slots__ to MemberDescriptorType docs (GH-108745) (GH-114536) (cherry picked from commit 6888cccac0776d965cc38a7240e1bdbacb952b91) Co-authored-by: plokmijnuhby <[email protected]> files: M Doc/library/types.rst diff --git a/Doc/library/types.rst b/Doc/library/types.rst index 3ce7ede4dec3a5..f9e0ba4567bef7 100644 --- a/Doc/library/types.rst +++ b/Doc/library/types.rst @@ -396,6 +396,10 @@ Standard names are defined for the following types: data members which use standard conversion functions; it has the same purpose as the :class:`property` type, but for classes defined in extension modules. + In addition, when a class is defined with a :attr:`~object.__slots__` attribute, then for + each slot, an instance of :class:`!MemberDescriptorType` will be added as an attribute + on the class. This allows the slot to appear in the class's :attr:`~object.__dict__`. + .. impl-detail:: In other implementations of Python, this type may be identical to _______________________________________________ Python-checkins mailing list -- [email protected] To unsubscribe send an email to [email protected] https://mail.python.org/mailman3/lists/python-checkins.python.org/ Member address: [email protected]
