mirror of
https://github.com/python/cpython.git
synced 2024-11-28 04:15:11 +08:00
Issue #23081: Document that PySequence_List also accepts iterables.
Patch by Lars Buitinck.
This commit is contained in:
parent
ce77ee9183
commit
32799953b0
@ -107,8 +107,9 @@ Sequence Protocol
|
||||
|
||||
.. c:function:: PyObject* PySequence_List(PyObject *o)
|
||||
|
||||
Return a list object with the same contents as the arbitrary sequence *o*. The
|
||||
returned list is guaranteed to be new.
|
||||
Return a list object with the same contents as the sequence or iterable *o*,
|
||||
or *NULL* on failure. The returned list is guaranteed to be new. This is
|
||||
equivalent to the Python expression ``list(o)``.
|
||||
|
||||
|
||||
.. c:function:: PyObject* PySequence_Tuple(PyObject *o)
|
||||
|
Loading…
Reference in New Issue
Block a user