[Python-checkins] cpython (3.4): Issue #23081: Document that PySequence_List also accepts iterables.
berker.peksag
python-checkins at python.org
Fri Mar 13 01:55:07 CET 2015
https://hg.python.org/cpython/rev/e31e987207ab
changeset: 94967:e31e987207ab
branch: 3.4
parent: 94965:b6fdf8c7a74d
user: Berker Peksag <berker.peksag at gmail.com>
date: Fri Mar 13 02:55:45 2015 +0200
summary:
Issue #23081: Document that PySequence_List also accepts iterables.
Patch by Lars Buitinck.
files:
Doc/c-api/sequence.rst | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/Doc/c-api/sequence.rst b/Doc/c-api/sequence.rst
--- a/Doc/c-api/sequence.rst
+++ b/Doc/c-api/sequence.rst
@@ -107,8 +107,9 @@
.. 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)
--
Repository URL: https://hg.python.org/cpython
More information about the Python-checkins
mailing list