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

2014-01-03 Thread Terry J. Reedy
Terry J. Reedy added the comment: 'name=val' in a signature (not a call) merely indicates that name has a default. The 2.x use of [] to indicate the the parameter with a default is optional was dropped as redundant in the 3.x docs. The 2.x; tee doc has [, n=2]. The 3.x doc is correctly accordi

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

2014-01-03 Thread Mark Lawrence
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(

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

2014-01-03 Thread Terry J. Reedy
Terry J. Reedy added the comment: It is an unfortunate (to my mind) but true fact that the docs do not indicate which functions are coded in C and for such functions, whether args passable by position can also be passed by name. If one wishes to pass by name, one simply has to experiment. The

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

2013-12-30 Thread py.user
Changes by py.user : -- status: open -> pending ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.py

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

2013-12-30 Thread py.user
py.user added the comment: for example http://docs.python.org/3/library/itertools.html#itertools.permutations has same description and it's a keyword compare "itertools.tee(iterable, n=2)" "itertools.permutations(iterable, r=None)" >>> itertools.permutations('abc') >>> itertools.permutations

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

2013-12-30 Thread py.user
Changes by py.user : -- status: closed -> pending ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.

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

2013-12-29 Thread Mark Lawrence
Mark Lawrence added the comment: It's just the docs that need changing to clarify the situation as (say) a,b,c = tee(range, 3) works perfectly. Sorry I didn't have the foresight to check this before :( -- components: +Documentation -Library (Lib) versions: +Python 2.7 ___

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

2013-12-29 Thread Mark Lawrence
Mark Lawrence added the comment: The docs for tee are the same going right back to its introduction in 2.4. The itertools count function takes start and step keywords, why can't tee take a keyword as it's documented to? -- ___ Python tracker

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

2013-12-29 Thread Mark Lawrence
Mark Lawrence added the comment: Why has this been closed? I've just run into exactly the same problem. It states here http://docs.python.org/3/library/itertools.html#itertools.tee "itertools.tee(iterable, n=2) - Return n independent iterators from a single iterable." -- nosy: +Brea

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

2013-06-26 Thread Raymond Hettinger
Changes by Raymond Hettinger : -- resolution: -> rejected status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mailing

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

2013-06-26 Thread py.user
py.user added the comment: tee() docs describe n as a keyword -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

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

2013-06-26 Thread Christian Heimes
Christian Heimes added the comment: A bunch builtin types and functions don't accept keyword args. kwargs make code slightly more complexity and a tiny bit slower. -- assignee: -> rhettinger nosy: +christian.heimes, rhettinger priority: normal -> low __

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

2013-06-26 Thread py.user
New submission from py.user: >>> import itertools >>> itertools.tee('x', n=2) Traceback (most recent call last): File "", line 1, in TypeError: tee() takes no keyword arguments >>> -- components: Library (Lib) messages: 191912 nosy: py.user priority: normal severity: normal status: op