[Python-ideas] Inline assignments using "given" clauses

Terry Reedy tjreedy at udel.edu
Thu May 10 16:21:29 EDT 2018


On 5/10/2018 9:44 AM, Guido van Rossum wrote:
> I'm sorry, but unless there's a sudden landslide of support for 'given' 
> in favor of ':=', I'm really not going to consider it.
> 
> I'd pronounce "if (x := y) > 0" as either "if y (assigned to x) is 
> greater than zero" or "if x (assigned from y) is greater than zero".

or "if x (bound to y) is greater than zero" ("do something with x").

-- 
Terry Jan Reedy



More information about the Python-ideas mailing list