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...| The Things That Toby Typed
Understanding how the co_await operator works can help to demystify the behaviour of coroutines and how they are suspended and resumed. In this post I will be explaining the mechanics of the co_await operator and introduce the related ‘Awaitable’ and ‘Awaiter’ type concepts.| Asymmetric Transfer
In this post I will describe the differences between functions and coroutines and provide a bit of theory about the operations they support. The aim of this post is introduce some foundational concepts that will help frame the way you think about C++ Coroutines.| Asymmetric Transfer