How the heck does async/await work in Python 3.5

Sven R. Kunze srkunze at mail.de
Tue Feb 23 11:50:05 EST 2016


On 23.02.2016 01:48, Ian Kelly wrote:
> On Mon, Feb 22, 2016 at 3:16 PM, Sven R. Kunze <srkunze at mail.de> wrote:
>> Is something like shown in 12:50 ( cout << tcp_reader(1000).get() ) possible
>> with asyncio? (tcp_reader would be async def)
> loop = asyncio.get_event_loop()
> print(loop.run_until_complete(tcp_reader(1000)))

I see. Thanks. :)

How come that Python (compared to C++) needs much more boilerplate to 
use async programming? Historically, it was the other way round.

Best,
Sven



More information about the Python-list mailing list