[Python-Dev] async/await in Python; v2

Greg Ewing greg.ewing at canterbury.ac.nz
Fri Apr 24 10:13:11 CEST 2015


Yury Selivanov wrote:

> If you have a future object 'fut', it's not intuitive
> or pythonic to write 'cocall fut()'.

Another way to approach that would be to provide
a cofunction await() used like this:

    cocall await(fut)

That would read more naturally and wouldn't require
modifying fut at all.

-- 
Greg


More information about the Python-Dev mailing list