What We’ve Been Awaiting For? - How to Build a C++ Coroutine Type - Hana Dusíková - C++Now 2024 @CppNow
What We’ve Been Awaiting For? - How to Build a C++ Coroutine Type - Hana Dusíková - C++Now 2024  @CppNow
Uploaded August 2024 | Updated December 2026, 3 hours ago
cppnow.org
---

What We’ve Been Awaiting For? - How to Build a C++ Coroutine Type - Hana Dusíková - C++Now 2024
---

How do you download a file from the internet in C++? In JavaScript it's really easy: just call the fetch function and await on the result.

In this talk I show how to gradually build a coroutine type, and how to make it as user friendly as possible. I will show you how to implement some async algorithms: waiting for all promises to finish, or waiting only for the first one to finish.

I will also go a little deeper and discuss what we've been missing and how coroutines should be improved; I would like to start a discussion about the correct form for such improvements, such as passing a scheduler or safe cancelling.

c++
co_return co_await all(
co_await fetch(url)
| ctre::search_all<R"(https?://[^"'s)]++)">
| std::views::transform(fetch_with_name)
);
---

Slides: github.com/boostcon/cppnow_presentations_2024/blob/main/Presentations/https://talks.cpp.fail/what-we-have-been-awaiting-for


---

Hana Dusíková

Hana is working as a staff software engineer in Woven by Toyota. She is author of CTRE (Compile Time Regular Expressions) library and member of WG21 (ISO C++ Committee) where she represent Czechia and chairs Study Group 7: Reflection and Compile Time Programming and co-chairs Evolution Working Group.

Hana is a badass. – Tony Van Eerd
---

C++Now 2025 - 28th April - 2nd May
C++Now is an annual onsite international C++ programming and coding conference held in Aspen, Colarado. For all C++ developers, C++ software engineers and those involved with the C++ language, CppNow provides an indepth and technical content provided by the best and brightest C++ experts of the C++ world.
Annual CppNow Conference - cppnow.org
linkedin.com/company/cppnow
twitter.com/cppnow
facebook.com/CppNow
reddit.com/r/CppNow
https://mastodon.social/@cppnow
think-cell develops one of the world’s leading PowerPoint applications, with C++ at the core of everything we build, from layout algorithms to deep integration with Microsoft Office. Interested in working on challenging C++ problems with real-world impact? Explore our open roles: think-cell.com/en/career/tech
---

Videos Filmed & Edited By Bash Films: bashfilms.com
YouTube Channel Managed & Optimized By Digital Medium Ltd: events.digital-medium.co.uk
---

#boost #cpp #cppprogramming #cplusplus #softwaredevelopment
What We’ve Been Awaiting For? - How to Build a C++ Coroutine Type - Hana Dusíková - C++Now 2024C++ Zero Overhead Pass by Value Through Invocable C++ Abstractions - Filipp Gelman - C++Now 2024Plato, Magritte, Sartre & Carroll - Learning Software Design from the Masters - Ben Deane - C++NowSPL - Open Source, Constexpr Library for Composing Algorithms - John Bandela - C++Now 2026Lightning Talk: Who Was William Shakespeare - Jon Kalb - C++Now 2025Lightning Talk: Building Presentations in slidev - Matt Kulukundis  - C++Now 2026Detect C++ Memory Leaks with ALSan: Attachable Leak Sanitizer - Bojun Seo - C++Now 2024Lightning Talk: Implementing an Observable with Friend Injection in C++ - Patrick Roberts - C++NowHow To Affect the Future of C++ Standard in 90 Minutes - River Wu - C++Now 2025Glean: C++ Code Indexing at Meta - Michael Park - C++Now 2024Lightning Talk: Source/Sink vs. Ranges in C++ - Whats the Difference? - Tony Van Eerd - CppNow 2023Welcome to v1.0 of the meta::[[verse]]! - Inbal Levi - C++Now 2025
CppNow |

What We’ve Been Awaiting For? - How to Build a C++ Coroutine Type - Hana Dusíková - C++Now 2024

SHARE TO X SHARE TO REDDIT SHARE TO FACEBOOK WALLPAPER