3 ms·
Another very nice and mind-bending presentation on coroutines, that eventually takes things so far that he creates a mini "OS" with coroutines as tasks, complet
by haberman 14y ago
Another very nice and mind-bending presentation on coroutines, that eventually takes things so far that he creates a mini "OS" with coroutines as tasks, complete with system calls and a scheduler: http://dabeaz.com/coroutines/ http://dabeaz.com/coroutines/
- webexcess 14y agoThank you, I hadn't seen that. I've added that link to the bottom of my article.
- beagle3 14y agoYou use "assert gen.next() is None", but asserts might be dropped by optimizations, see e.g. http://docs.python.org/release/2.5.2/ref/assert.html http://docs.python.org/release/2.5.2/ref/assert.html - and your code will break. assert should only be used for debugging, and only for things that should never happen. side effects on assert is a no-no. (Also in C)
- manaskarekar 14y agoThe talk by the same David Beazley on Co-routines: http://blip.tv/pycon-us-videos-2009-2010-2011/a-curious-course-on-coroutines-and-concurrency-part-001-2006228 http://blip.tv/pycon-us-videos-2009-2010-2011/a-curious-cour... The talk from David Mertz on Co-routines: https://www.youtube.com/watch?v=b7R3-_ViNxk https://www.youtube.com/watch?v=b7R3-_ViNxk
- mapleoin 14y agoWow that David Beazley presentation is annoying. He spends the first 10 minutes in the introduction, complaining about how he won't have enough time to go through his presentation.
- d23 14y agoI didn't watch the video, but going through the slides I was absolutely fascinated. I've been craving something new and advanced like this out of python for a while.