pep 530: Mark as accepted; clarify awaits in "if" clause
This commit is contained in:
parent
af9b67843d
commit
e40bf4d5cc
22
pep-0530.txt
22
pep-0530.txt
|
@ -4,7 +4,7 @@ Version: $Revision$
|
||||||
Last-Modified: $Date$
|
Last-Modified: $Date$
|
||||||
Author: Yury Selivanov <yury@magic.io>
|
Author: Yury Selivanov <yury@magic.io>
|
||||||
Discussions-To: <python-dev@python.org>
|
Discussions-To: <python-dev@python.org>
|
||||||
Status: Draft
|
Status: Accepted
|
||||||
Type: Standards Track
|
Type: Standards Track
|
||||||
Content-Type: text/x-rst
|
Content-Type: text/x-rst
|
||||||
Created: 03-Sep-2016
|
Created: 03-Sep-2016
|
||||||
|
@ -96,10 +96,18 @@ asynchronous and synchronous comprehensions::
|
||||||
result = {await fun() for fun in funcs}
|
result = {await fun() for fun in funcs}
|
||||||
result = {fun: await fun() for fun in funcs}
|
result = {fun: await fun() for fun in funcs}
|
||||||
|
|
||||||
|
result = [await fun() for fun in funcs if await smth]
|
||||||
|
result = {await fun() for fun in funcs if await smth}
|
||||||
|
result = {fun: await fun() for fun in funcs if await smth}
|
||||||
|
|
||||||
result = [await fun() async for fun in funcs]
|
result = [await fun() async for fun in funcs]
|
||||||
result = {await fun() async for fun in funcs}
|
result = {await fun() async for fun in funcs}
|
||||||
result = {fun: await fun() async for fun in funcs}
|
result = {fun: await fun() async for fun in funcs}
|
||||||
|
|
||||||
|
result = [await fun() async for fun in funcs if await smth]
|
||||||
|
result = {await fun() async for fun in funcs if await smth}
|
||||||
|
result = {fun: await fun() async for fun in funcs if await smth}
|
||||||
|
|
||||||
This is only valid in ``async def`` function body.
|
This is only valid in ``async def`` function body.
|
||||||
|
|
||||||
|
|
||||||
|
@ -120,6 +128,18 @@ Backwards Compatibility
|
||||||
The proposal is fully backwards compatible.
|
The proposal is fully backwards compatible.
|
||||||
|
|
||||||
|
|
||||||
|
Acceptance
|
||||||
|
==========
|
||||||
|
|
||||||
|
PEP 530 was accepted by Guido, September 6, 2016 [1]_.
|
||||||
|
|
||||||
|
|
||||||
|
References
|
||||||
|
==========
|
||||||
|
|
||||||
|
[1] https://mail.python.org/pipermail/python-ideas/2016-September/042141.html
|
||||||
|
|
||||||
|
|
||||||
Copyright
|
Copyright
|
||||||
=========
|
=========
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue