mirror of
https://github.com/python/cpython.git
synced 2025-12-04 00:30:19 +00:00
gh-111696, PEP 737: Add PyType_GetFullyQualifiedName() function (#116815)
Rewrite tests on type names in Python, they were written in C.
This commit is contained in:
parent
b54d7c87aa
commit
19c3a2ff91
11 changed files with 161 additions and 94 deletions
|
|
@ -185,6 +185,14 @@ Type Objects
|
|||
|
||||
.. versionadded:: 3.11
|
||||
|
||||
.. c:function:: PyObject* PyType_GetFullyQualifiedName(PyTypeObject *type)
|
||||
|
||||
Return the type's fully qualified name. Equivalent to
|
||||
``f"{type.__module__}.{type.__qualname__}"``, or ``type.__qualname__`` if
|
||||
``type.__module__`` is not a string or is equal to ``"builtins"``.
|
||||
|
||||
.. versionadded:: 3.13
|
||||
|
||||
.. c:function:: void* PyType_GetSlot(PyTypeObject *type, int slot)
|
||||
|
||||
Return the function pointer stored in the given slot. If the
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue