pFad - Phone/Frame/Anonymizer/Declutterfier! Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

URL: http://github.com/python/cpython/commit/2bac2b86b1486f15038fb246835e04bb1b213cd8

9241e157469407.css" /> gh-121403: Add notes for PyList_GetXXX APIs about the need for init (… · python/cpython@2bac2b8 · GitHub
Skip to content

Commit 2bac2b8

Browse files
authored
gh-121403: Add notes for PyList_GetXXX APIs about the need for init (gh-121626)
1 parent 498a94c commit 2bac2b8

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

Doc/c-api/list.rst

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,9 +38,12 @@ List Objects
3838
.. note::
3939
4040
If *len* is greater than zero, the returned list object's items are
41-
set to ``NULL``. Thus you cannot use abstract API functions such as
42-
:c:func:`PySequence_SetItem` or expose the object to Python code before
43-
setting all items to a real object with :c:func:`PyList_SetItem`.
41+
set to ``NULL``. Thus you cannot use abstract API functions such as
42+
:c:func:`PySequence_SetItem` or expose the object to Python code before
43+
setting all items to a real object with :c:func:`PyList_SetItem` or
44+
:c:func:`PyList_SET_ITEM()`. The following APIs are safe APIs before
45+
the list is fully initialized: :c:func:`PyList_SetItem()` and :c:func:`PyList_SET_ITEM()`.
46+
4447
4548
4649
.. c:function:: Py_ssize_t PyList_Size(PyObject *list)

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad © 2024 Your Company Name. All rights reserved.





Check this box to remove all script contents from the fetched content.



Check this box to remove all images from the fetched content.


Check this box to remove all CSS styles from the fetched content.


Check this box to keep images inefficiently compressed and original size.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy