A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2018-April/153091.html below:

[Python-Dev] (name := expression) doesn't fit the narrative of PEP 20

[Python-Dev] (name := expression) doesn't fit the narrative of PEP 20 [Python-Dev] (name := expression) doesn't fit the narrative of PEP 20Greg Ewing greg.ewing at canterbury.ac.nz
Thu Apr 26 03:16:28 EDT 2018
Tim Peters wrote:
> As a statement in a program (as opposed to typed at a shell),
> "a := 3" has the unnecessary (in that context) property of returning
> (and discarding 3), so it's better style to use "a = 3" in that
> context.

That seems like a post-hoc justification. If := were the one
and only assignment symbol, the compiler could easily optimise
away the extra DUP_TOP or whatever is involved.

-- 
Greg
More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4