Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is a cofunction and how would it work in Python?

I am reading PEP-3153, but I don't understand what the problem is it wants to address. Could you please explain?

like image 588
Stefano Borini Avatar asked Feb 25 '11 21:02

Stefano Borini


1 Answers

You can Google "Python coroutines" and get a lot of good information. Here is a presentation (PDF) I ran across some time ago that seemed pretty good to me about the how and why. The source code is also available (this includes the PDF, so if you want both, just download this). The home page for this presentation has links to the individual source files.

like image 106
kindall Avatar answered Sep 30 '22 19:09

kindall