3 ms·
Coroutines in D
- wccrawford 15y agoI get a little confused there. He starts out talking about doing 2 things at once, walking and breathing. Then modifies it so you are only breathing after you start walking. So it's not really doing the same thing any more. Then goes on to say you want to do both things, but don't need to do both at once... And it looks like the fibers simply call each other and wait until they are finished doing what they do. How is this better than just calling the methods? It doesn't seem be easier to read, and doesn't seem to be multi-threaded.