[Python-Dev] Features for Python 2.0

Thomas Wouters thomas@xs4all.net
Tue, 25 Jul 2000 15:28:37 +0200


On Tue, Jul 25, 2000 at 08:53:05AM -0500, Guido van Rossum wrote:

> If you folks hadn't wasted so much time discussion augmented print
> statements and new operators, we could have had the augmented
> assignments and list comprehensions checked in already!

I don't think the augmented assignment patch is ready to be checked in,
though !

There are a number of crude hacks that might be solved better: the
2-argument opcodes, for instance, could posisbly be avoided by abusing the
proposed 'extended_arg' opcode. And the patch re-uses the binary opcodes as
augmented-assignment opcodes, merely because those #defines were already
available in both ceval.c and compile.c: this would 'break' if we wanted to
incorporate a new operator in augmented-assignment without adding a new
'normal' opcode for that operator.

I'm still working on the PEP, really :) It's just a pretty long one, trying
to explain all the intricate details and the simple elegance of the solution
<wink>. Perhaps it'll inspire some discussion in the details of the patch,
too.

Humb-ly y'rs,
-- 
Thomas Wouters <thomas@xs4all.net>

Hi! I'm a .signature virus! copy me into your .signature file to help me spread!