Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 16 additions & 0 deletions Doc/c-api/intro.rst
Original file line number Diff line number Diff line change
Expand Up @@ -919,6 +919,22 @@ use them.
See :pep:`353` for details. ``PY_SSIZE_T_MAX`` is the largest positive value
of type :c:type:`Py_ssize_t`.

.. c:type:: Py_intptr_t
A signed integral type such that a legitimate ``void*`` can be cast to
:c:type:`Py_intptr_t` and then back to ``void*`` again without loss of
information.

Kept for backwards compatibility; prefer using ``intptr_t`` directly.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Should these be marked as .. soft-deprecated then?


.. c:type:: Py_uintptr_t
An unsigned integral type such that a legitimate ``void*`` can be cast to
:c:type:`Py_uintptr_t` and then back to ``void*`` again without loss of
information.

Kept for backwards compatibility; prefer using ``uintptr_t`` directly.


.. _api-exceptions:

Expand Down
3 changes: 3 additions & 0 deletions Doc/c-api/weakref.rst
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@ specific object types which directly implement weak references. The first is a
simple reference object, and the second acts as a proxy for the original object
as much as it can.

.. c:type:: PyWeakReference
The C structure of the objects used to describe weak references objects.

.. c:function:: int PyWeakref_Check(PyObject *ob)
Expand Down
16 changes: 16 additions & 0 deletions Doc/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -234,6 +234,22 @@
('py:attr', '__wrapped__'),
]

# Objects present in the stable_abi.dat but removed from the docs
# or with suppressed references to them.
nitpick_ignore += [
# pending removal in Python 3.16
('c:data', 'Py_FileSystemDefaultEncodeErrors'),
('c:data', 'Py_FileSystemDefaultEncoding'),
('c:data', 'Py_HasFileSystemDefaultEncoding'),
('c:data', 'Py_UTF8Mode'),
# legacy typedefs for sq_slice and sq_ass_slice
('c:type', 'ssizessizeargfunc'),
('c:type', 'ssizessizeobjargproc'),
# 'symtable' was exposed by symtable.h but removed in 3.10.
# See https://github.com/python/cpython/pull/24910.
('c:type', 'symtable'),
]

# gh-106948: Copy standard C types declared in the "c:type" domain and C
# structures declared in the "c:struct" domain to the "c:identifier" domain,
# since "c:function" markup looks for types in the "c:identifier" domain. Use
Expand Down
Loading