New submission from Sergey Fedoseev <fedoseev.ser...@gmail.com>:

In [3]: help(zip)

class zip(object)
 |  zip(*iterables) --> zip object
 |  
 |  Return a zip object whose .__next__() method returns a tuple where
 |  the i-th element comes from the i-th iterable argument.  The .__next__()
 |  method continues until the shortest iterable in the argument sequence
 |  is exhausted and then it raises StopIteration.

This description is awkward and should use term 'iterator' as 
https://docs.python.org/3/library/functions.html#zip does.

The same applies to chain(), count() and zip_longest() from itertools.

----------
assignee: docs@python
components: Documentation
messages: 350704
nosy: docs@python, sir-sigurd
priority: normal
severity: normal
status: open
title: zip() docstring should say 'iterator' instead of 'object with __next__()'

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue37974>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to