
On Thu, Dec 19, 2013 at 5:51 AM, Carlos Ferreira
simple object and inherit the boost::coroutines::coroutine template.
ex: <snip/>
Is this right? Can I actually inherit from the boost::coroutines::coroutine template ? If yes, how can I proceed from here, to use the run() object method as the coroutine itself, with an io_service provided through the constructor ?
Um. It's much more typical to instantiate a coroutine, passing it the code you want to run. That can be an object method, run() or whatever: use boost::bind() to bind the object pointer/reference to the method, along with any other parameters you want to pass it initially. I would have to let Oliver respond to the question about whether it's acceptable to derive from the coroutine template. But I claim that it will perplex future maintainers.