[Python-Dev] Re: "groupby" iterator
Michael Hudson
mwh at python.net
Wed Dec 3 05:39:05 EST 2003
Guido van Rossum <guido at python.org> writes:
>> Doesn't have to be a keyword... I implemented something like this
>> years ago and then ditched it when list comps appeared.
>>
>> It would let you do things like
>>
>> >>> map(X + 1, range(2))
>> [1, 2, 3]
>
> What was your notation like? Did you actually use 'X'?
Um, I think so. I defined it in my $PYTHONSTARTUP file as an instance
of a class _X, or something like that.
Cheers,
mwh
--
In many ways, it's a dull language, borrowing solid old concepts
from many other languages & styles: boring syntax, unsurprising
semantics, few automatic coercions, etc etc. But that's one of
the things I like about it. -- Tim Peters, 16 Sep 93
More information about the Python-Dev
mailing list