]> granicus.if.org Git - python/commit
Small changes to map() and filter():
authorGuido van Rossum <guido@python.org>
Fri, 10 Jul 1998 17:37:30 +0000 (17:37 +0000)
committerGuido van Rossum <guido@python.org>
Fri, 10 Jul 1998 17:37:30 +0000 (17:37 +0000)
commitfa4ac71dd6602347d80e4cdb71f3867fb63d3578
tree3e2d2bd1f36093765fa1f81576c13b64e368211d
parentbfc725bf64c1da301fe29b9722efc56e34799cf4
Small changes to map() and filter():

(1) If a sequence S is shorter than len(S) indicated, don't fail --
just use the shorter size.  (I.e, len(S) is just a hint.)

(2) Implement the special case map(None, S) as list(S) -- it's faster.
Python/bltinmodule.c