~/talk

C++ Feature Coroutines, Beginner Friendly

Talkat CppNorth 2023 · 2023-07-17..07-19· [concurrency]
slides:none on file

Covers the concrete mechanics: new keywords co_await, co_yield, co_return map to promise_type hooks and a wrapper return type; every coroutine creates a coroutine frame on the heap (a dynamic allocation unless avoided); shows a chat example with listen/answer, implements no STL generator fallback (generator + iterator for range‑for), an interleave of two vectors, and a scheduler that stores handles in a std::list using coroutine_handle<void> to round‑robin tasks. Also demonstrates a byte‑stream parser using co_await per byte, details exception propagation and restrictions (no constexpr/constructor/destructor/main coroutines).

AI-written summary · about

  1. 0:00Introduction and setup
  2. 3:54Functions vs coroutines
  3. 16:57First coroutine example
  4. 34:34Interleaving vectors
  5. 46:15Adding iterators
  6. 46:36Cooperative multitasking
  7. 55:12Parsing data streams
  8. 1:07:45Handling exceptions
  9. 1:13:03Limitations and restrictions
  10. 1:15:10Q&A and closing
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.