Add missing generator functions to the in-place class.
Add helper functions for manipulating resumable lambdas.

These helpers are used to prevent compile errors from the preprocessor, due to
real lambdas not having member functions like is_terminal().