]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
[3.11] gh-107298: Fix more Sphinx warnings in the C API doc (GH-107329) (GH-107377)
authorSerhiy Storchaka <storchaka@gmail.com>
Fri, 28 Jul 2023 07:03:47 +0000 (10:03 +0300)
committerGitHub <noreply@github.com>
Fri, 28 Jul 2023 07:03:47 +0000 (07:03 +0000)
commit32e17d4a3c1da2a8ff082b5cb4f3cd13688a95a1
tree23823b6366d409c3bbb5e8018cc1f039121090fe
parentdcfdfa539964a66fcc39722bada52e440f06a877
[3.11] gh-107298: Fix more Sphinx warnings in the C API doc (GH-107329) (GH-107377)

Declare the following functions as macros, since they are actually
macros. It avoids a warning on "TYPE" or "macro" argument.

* PyMem_New()
* PyMem_Resize()
* PyModule_AddIntMacro()
* PyModule_AddStringMacro()
* PyObject_GC_New()
* PyObject_GC_NewVar()
* PyObject_New()
* PyObject_NewVar()

(cherry picked from commit 8d61a71f9c81619e34d4a30b625922ebc83c561b)

Co-authored-by: Victor Stinner <vstinner@python.org>
22 files changed:
Doc/c-api/allocation.rst
Doc/c-api/capsule.rst
Doc/c-api/complex.rst
Doc/c-api/conversion.rst
Doc/c-api/exceptions.rst
Doc/c-api/gcsupport.rst
Doc/c-api/import.rst
Doc/c-api/init.rst
Doc/c-api/init_config.rst
Doc/c-api/memory.rst
Doc/c-api/module.rst
Doc/c-api/set.rst
Doc/c-api/structures.rst
Doc/c-api/sys.rst
Doc/c-api/typeobj.rst
Doc/c-api/unicode.rst
Doc/conf.py
Doc/extending/extending.rst
Doc/extending/newtypes_tutorial.rst
Doc/whatsnew/2.3.rst
Doc/whatsnew/3.8.rst
Doc/whatsnew/3.9.rst