[Python-ideas] async/await in Python

Greg greg.ewing at canterbury.ac.nz
Mon Apr 20 06:48:03 CEST 2015


On 20/04/2015 3:22 p.m., Andrew Barnert wrote:
> If we have to
> explain that "Yes, Python has coroutines just like C#, but we call
> them cofunctions, and we have these other things that are similar but
> different and not compatible that we call coroutines"

To my way of thinking, a cofunction is a particular way of
implementing a coroutine, in the same way that a generator
function is a particular way of implementing an iterator.

In other words, it's not cofunction vs. coroutine; rather,
cofunctions and generators are both kinds of coroutine.

-- 
Greg


More information about the Python-ideas mailing list