summaryrefslogtreecommitdiffstats
path: root/Misc
diff options
context:
space:
mode:
authorTim Peters <tim.peters@gmail.com>2001-05-03 23:54:49 (GMT)
committerTim Peters <tim.peters@gmail.com>2001-05-03 23:54:49 (GMT)
commit4e9afdca392668bc7e07c79d8af0f95ef497fba4 (patch)
tree1d5fe4e4a32f838e7ae7189c49a7ae42fc139f51 /Misc
parent6aebded915ac3ca6dcd99ea4bf3dfc47a31bab1e (diff)
downloadcpython-4e9afdca392668bc7e07c79d8af0f95ef497fba4.zip
cpython-4e9afdca392668bc7e07c79d8af0f95ef497fba4.tar.gz
cpython-4e9afdca392668bc7e07c79d8af0f95ef497fba4.tar.bz2
Generalize map() to work with iterators.
NEEDS DOC CHANGES. Possibly contentious: The first time s.next() yields StopIteration (for a given map argument s) is the last time map() *tries* s.next(). That is, if other sequence args are longer, s will never again contribute anything but None values to the result, even if trying s.next() again could yield another result. This is the same behavior map() used to have wrt IndexError, so it's the only way to be wholly backward-compatible. I'm not a fan of letting StopIteration mean "try again later" anyway.
Diffstat (limited to 'Misc')
-rw-r--r--Misc/NEWS1
1 files changed, 1 insertions, 0 deletions
diff --git a/Misc/NEWS b/Misc/NEWS
index 9d84845..617146c 100644
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -19,6 +19,7 @@ Core
arguments:
filter()
list()
+ map()
max()
min()