Am I the only one who would love these extentions? - Python 3.0 proposals (long)

Alex Martelli aleax at aleax.it
Tue Nov 11 05:47:46 EST 2003


Andrew Dalke wrote:
   ...
> and I think changing
>   FTEXT, FHCRC, FEXTRA, FNAME, FCOMMENT = 1, 2, 4, 8, 16
> into
>   FTEXT, FHCRC, FEXTRA, FNAME, FCOMMENT, ... = x*x for x in
> itertools.count(1)
> is just plain stupid.

Not necessarily stupid, but it sure IS semantics-altering (as well
as syntactically incorrect in the proposed 2.4 syntax for genexps --
you'll need parentheses around a genexp) -- a sequence of squares
rather than one of powers of two.
(2**x for x in itertools.count()), however, would be fine:-).


> Therefore I withdraw this proposal, leaving it for contemplation and
> posterity's.

I think you just grabbed the record for shortest-lived proposal
in Python's history.  Applause, applause!-).


Alex





More information about the Python-list mailing list