Loading…
Subject: Functional clear filter
arrow_back View All Dates
Thursday, September 17
 

09:00 MDT

Beyond Monads: Pattern Matching Alternatives for Result Types
Thursday September 17, 2026 09:00 - 10:00 MDT
In C++, monadic operations are a commonly utilized API for interacting with result types like std::optional and std::expected. By chaining the computations, these abstractions allow you to manipulate the underlying values using less boilerplate code. Monadic operations are a powerful tool suitable for a variety of usage scenarios. They enhance code robustness and significantly lower the risk of accidental errors.

Despite its benefits, many users consider the syntax of monadic operations to be overly verbose, and the underlying concept often seems complicated. There are also the cases where the restrictions placed on functions require using extra statements, specific return and arguments types, and reduce code readability. However, are there other options available? Do we have promising alternatives? The short answer is: yes. While C++ does not yet include pattern matching as a native language feature, the standard library still offers tools for achieving many useful pattern-matching-like functionalities. We will explore how to apply std::visit to this problem and evaluate if an abstraction, which we might call std::match, could serve as an effective substitute for monadic operations in various situations.

Based on several years of practical production experience, this talk will explore the use of monadic result type interfaces and comparable alternatives. This information will benefit practicing software engineers looking to deepen their understanding of these features and integrate them into their codebases.

Presenters
avatar for Vitaly Fanaskov

Vitaly Fanaskov

Principal Software Engineer, reMarkable
Vitaly Fanaskov is a Principal Software Engineer at reMarkable. He has been designing and developing software using C++ and some other languages for over a decade. Primary areas of interest are design and development of frameworks and libraries, modern programming languages, and functional... Read More →
Thursday September 17, 2026 09:00 - 10:00 MDT
Red Rock 6/7

09:00 MDT

Composing the Future: Async Workflows with std::execution
Thursday September 17, 2026 09:00 - 10:00 MDT
Software development has now shifted decisively to a distributed, asynchronous paradigm, in which engineers must manage code that may be executing on parallel threads, or on a different machine. Many mainstream programming languages have adapted themselves to this new world. For example, JavaScript has promises and async/await, Python has asyncio, Rust offers zero-cost async/await with compile-time safety, and Go built goroutines and channels as first-class primitives.

C++ developers face the same challenge but have been left without a standard solution. As a result, much production code remains stuck in “callback hell,” where control flow is inverted, error handling is duplicated at every level, and common patterns like "run A and B in parallel, and then combine results" must be hand-rolled every time.

This is not simply a matter of bolting async/await onto C++. Deterministic destruction, zero-overhead abstraction, and precise control over memory and lifetimes, these very properties making C++ powerful dictate that an async framework cannot rely on a garbage collector or managed runtime to paper over complexity. It must earn its place by working with the language's ownership model, not around it.

std::execution is C++’s answer to this problem. Introduced as part of C++ 26, it solves this through composable senders: lazy, type-safe descriptions of work that can be chained, branched, and parallelized before being submitted to an execution context. Like Swift's structured concurrency, std::execution enforces structured lifetimes so that async work cannot silently outlive its scope.

This talk aims to provide application developers with an introduction to the current proposal and give them a grounding in the fundamentals that can be applied in real-world applications. We will walk through several worked examples: from simple chains to parallel fan-out with error propagation, showing side-by-side comparisons with callback-based equivalents to make the advantages more concrete and relatable.

This talk assumes no knowledge of the std::execution framework and no expertise in async programming, though practical, real-world experience will certainly help ground the examples. Attendees will leave with a working understanding of the sender/receiver model, practical patterns they can use, and a clear picture of what structured concurrency means for C++.

Presenters
avatar for Alistair Fisher

Alistair Fisher

Alistair Fisher is an Engineering Team Lead at Bloomberg. He works in the Multi-Asset Risk System (MARS) Pricing group in London, where he is focused on building scalable and reliable components for portfolio pricing and risk analysis. He is interested in the use of functional programming... Read More →
avatar for Ivy Zhang

Ivy Zhang

Bloomberg LP
Ivy is a Software Engineer at Bloomberg, where she works on the company's high throughput multi-asset execution management system. She is a Technical Rep at Bloomberg and active member of C++ Guild. She holds a bachelor's degree in Computer Science and Chemical Biological Engineering... Read More →
Thursday September 17, 2026 09:00 - 10:00 MDT
Colorado B
 
Share Modal

Share this link via

Or copy link

Filter sessions
Apply filters to sessions.
Filtered by Date -