PEP-0315--Enhanced While Loop: An idea for an alternative syntax

Joe Mason joe at notcharles.ca
Thu Feb 19 02:26:04 EST 2004


In article <7xd68bzs79.fsf at ruckus.brouhaha.com>, Paul Rubin wrote:
> Joe Mason <joe at notcharles.ca> writes:
>> > There's nothing implicit about an assignment expression.
>> 
>> Except the return value.
> 
> Huh?  It's an expression, the value is explicit.

x = 1 (or x := 1) looks to me like a statement that sets x to 1, not an
expression.  I wouldn't expect any return value, if my mind hadn't been
corrupted by C.  So the fact that there's a return value at all is
implicit.

Joe



More information about the Python-list mailing list