[issue18310] itertools.tee() can't accept keyword arguments

Mark Lawrence report at bugs.python.org
Sat Jan 4 04:56:31 CET 2014


Mark Lawrence added the comment:

>From the glossary

Quote

keyword argument: an argument preceded by an identifier (e.g. name=) in a function call or passed as a value in a dictionary preceded by **. For example, 3 and 5 are both keyword arguments in the following calls to complex():

complex(real=3, imag=5)
complex(**{'real': 3, 'imag': 5})

End Quote

>From itertools docs "itertools.tee(iterable, n=2) Return n independent iterators from a single iterable", so what is this if it's not a keyword argument?  Surely all that's needed in this case is for the docs to read "itertools.tee(iterable[, n]) Return n independent iterators from a single iterable where n defaults to 2"

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue18310>
_______________________________________


More information about the Python-bugs-list mailing list