Interactions with futures
LegNeato opened this issue · comments
Hello! I was pointed to this library and it is pretty cool, thank you for making it.
How do these coroutines interact with futures? Can a coroutine be a future executor? Can futures run on a coroutine? Are there any limitations interacting across? Sorry, I am not too familiar with the stack unwinding machinery, drop, and such in Rust but from the README it looks like there are some different tradeoffs vs futures that might be incompatible?
Coroutines are very similar to futures, and in fact it's possible to implement a Future
wrapper around a coroutine. For an example, see async-wormhole which does this (based on a different coroutine implementation, but the API is very similar).
Great, thanks!