Traditionally, C++ functions that take parameters by reference have been able to rely on the objects bound to such references outliving the execution of the function. However, things are not so simple when your function is a coroutine; such functions can be suspended and resumed, returning to their caller before they have finished executing. In this article I show how this violation of long-standing expectations can lead to subtle bugs in coroutine code and describe some approaches for avoidi...