[Python-3000] Is this really a SyntaxError?

Steven Bethard steven.bethard at gmail.com
Tue Jul 29 22:02:10 CEST 2008


On Tue, Jul 29, 2008 at 1:48 PM, Georg Brandl <g.brandl at gmx.net> wrote:
> Georg Brandl schrieb:
>>
>> Someone just wrote to the docs mailing list and reported that the
>> itertools
>> documentation for Py3k contains this recipe:
>>
>> def grouper(n, iterable, fillvalue=None):
>>     args = [iter(iterable)] * n
>>     return zip_longest(*args, fillvalue=fillvalue)
>>
>> It is currently a syntax error in 3k. There's also a test for it in
>> test_keywordonlyarg.py, however, I can currently see no reason why
>> it should be disallowed.
>
> No opinions at all?

FWIW, I'd be happy to see this allowed. I know I've wished I could do
this once or twice before.

Steve
-- 
I'm not *in*-sane. Indeed, I am so far *out* of sane that you appear a
tiny blip on the distant coast of sanity.
        --- Bucky Katt, Get Fuzzy


More information about the Python-3000 mailing list