ScummVM API documentation
Common::CoroContextHolder Class Reference

#include <coroutines.h>

Public Member Functions

 CoroContextHolder (CoroContext &ctx)
 

Detailed Description

Wrapper class which holds a pointer to a pointer to a CoroBaseContext. Note that the destructor kills the context being held, but ONLY if the _sleep val of that context is zero. This way, a coroutine can just 'return' without freeing the allocated context (in Simon Tatham's original code, one had to use a special macro to return from a coroutine).


The documentation for this class was generated from the following file: