On 04/12/2018 09:52 PM, Chris Angelico wrote:
foo := a > b # does this capture 'a', or 'a > b'?
bar := c + d # 'c' or 'c + d'?
I'm open to argument here, but my thinking is that these should
capture 'a' and 'c + d'.
I think := should act the same as = or there will be plenty of confusion. If one wants to capture less then parenthesis
can be used to narrow it down:
(foo := a) > b
Looked at another way -- you already have the value named as 'a', so why would
you also name it as 'foo'?
Python-ideas mailing list
Code of Conduct: http://python.org/psf/codeofconduct/