cpython: 1d4849f9e37d (original) (raw)
Mercurial > cpython
changeset 82216:1d4849f9e37d 3.2
#17178: update any()/all() docstrings to document their behavior with empty iterables. Patch by Ankur Ankan. [#17178]
Ezio Melotti ezio.melotti@gmail.com | |
---|---|
date | Fri, 15 Feb 2013 23:35:14 +0200 |
parents | 8753a3be4a3c |
children | 34cfe145b286 472a7c652cbd |
files | Misc/ACKS Python/bltinmodule.c |
diffstat | 2 files changed, 5 insertions(+), 2 deletions(-)[+] [-] Misc/ACKS 1 Python/bltinmodule.c 6 |
line wrap: on
line diff
--- a/Misc/ACKS +++ b/Misc/ACKS @@ -37,6 +37,7 @@ Erik Andersén Oliver Andrich Ross Andrus Jérémy Anger +Ankur Ankan Jon Anglin Heidi Annexstad Éric Araujo
--- a/Python/bltinmodule.c +++ b/Python/bltinmodule.c @@ -262,7 +262,8 @@ builtin_all(PyObject *self, PyObject *v) PyDoc_STRVAR(all_doc, "all(iterable) -> bool\n[](#l2.5) \n[](#l2.6) -Return True if bool(x) is True for all values x in the iterable."); +Return True if bool(x) is True for all values x in the iterable.\n[](#l2.8) +If the iterable is empty, return True."); static PyObject * builtin_any(PyObject *self, PyObject *v) @@ -304,7 +305,8 @@ builtin_any(PyObject *self, PyObject *v) PyDoc_STRVAR(any_doc, "any(iterable) -> bool\n[](#l2.15) \n[](#l2.16) -Return True if bool(x) is True for any x in the iterable."); +Return True if bool(x) is True for any x in the iterable.\n[](#l2.18) +If the iterable is empty, return False."); static PyObject * builtin_ascii(PyObject *self, PyObject *v)