Staging
v0.5.1
https://github.com/python/cpython
Revision 87c87b5bd6f6a5924b485398f353308410f9d8c1 authored by Pablo Galindo on 18 November 2020, 23:44:30 UTC, committed by GitHub on 18 November 2020, 23:44:30 UTC
Currently walruses are not allowerd in set literals and set comprehensions:

>>> {y := 4, 4**2, 3**3}
  File "<stdin>", line 1
    {y := 4, 4**2, 3**3}
       ^
SyntaxError: invalid syntax

but they should be allowed as well per PEP 572.
(cherry picked from commit b0aba1fcdc3da952698d99aec2334faa79a8b68c)

Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
1 parent 36619e1
History
Tip revision: 87c87b5bd6f6a5924b485398f353308410f9d8c1 authored by Pablo Galindo on 18 November 2020, 23:44:30 UTC
[3.9] bpo-42381: Allow walrus in set literals and set comprehensions (GH-23332) (GH-23333)
Tip revision: 87c87b5
File Mode Size
workflows
CODEOWNERS -rw-r--r-- 3.9 KB
CONTRIBUTING.rst -rw-r--r-- 2.4 KB
FUNDING.yml -rw-r--r-- 57 bytes
PULL_REQUEST_TEMPLATE.md -rw-r--r-- 700 bytes
SECURITY.md -rw-r--r-- 530 bytes
codecov.yml -rw-r--r-- 485 bytes

back to top