14.8. Async Comprehension
Asynchronous Comprehensions https://peps.python.org/pep-0530/
14.8.1. Recap
>>>
... result = []
... async for i in aiter():
... if i % 2:
... result.append(i)
14.8.2. Example
>>> result = [i async for i in aiter() if i % 2]
>>> result = [await fun() for fun in funcs]
>>> result = {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 = {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}