Range adaptors – 5 years after C++20 -- Hannes Hauswedell
A look back on major design decisions in C++ Ranges and how they may be viewed today.
Range adaptors - 5 years after C++20
by Hannes Hauswedell
Watch now:
March 11-13, Online
March 16-18, Madrid, Spain
March 23-28, Croydon, London, UK
March 30, Kortrijk, Belgium
May 4-8, Aspen, CO, USA
May 4-8, Toronto, Canada
June 8 to 13, Brno, Czechia
June 17-20, Folkestone, UK
September 12-18, Aurora, CO, USA
November 6-8, Berlin, Germany
November 16-21, Búzios, Rio De Janeiro, Brazil
By Hannes Hauswedell | Feb 23, 2026 03:18 PM | Tags: None
A look back on major design decisions in C++ Ranges and how they may be viewed today.
Range adaptors - 5 years after C++20
by Hannes Hauswedell
Watch now:
<iframe allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" allowfullscreen="" frameborder="0" height="315" referrerpolicy="strict-origin-when-cross-origin" src="https://www.youtube-nocookie.com/embed/nficAvk5RA4?si=w86EVk7oX89uVcPg" title="YouTube video player" width="560"></iframe>
By AOrefkov | Feb 19, 2026 01:03 PM | Tags: None
So how do you quickly concatenate strings?
By Aleksandr Orefkov
From the article:
All practicing programmers have to concatenate strings. Precisely concatenate, we don’t have some JavaScript or PHP, in C++ we have this fancy word for it. Programmers in other languages simply “add” strings together without much thought, without even thinking about this operation. After all, what could be simpler than
return "The answer is " + str_answer + ", count is " + count;But while it’s forgivable for script kiddies not to think about the meaning behind such a simple notation, it’s unacceptable for an experienced developer to approach such an important issue so irresponsibly. An experienced developer, imagining such C++ code, immediately sees the terrifying abyss of problems that such an approach can create.
What type is str_answer? What type is count? “The answer is “ and “, count is “ - are literals that add to std::string as a const char*. So, strlen will be called. I wonder if the compiler will be able to optimize and calculate their length at compile time? Oh well, it seems like constexpr is in the addition, let’s hope so.
This is the first level of problems for now. And let’s say we successfully solved them, creating the following code:std::string make_answer(std::string_view str_answer, int count) { return "The answer is " + std::string{str_answer} + ", count is " + std::to_string(count); }It sounds like “Hurray!”, but it’s somehow not loud enough…
By Blog Staff | Feb 17, 2026 04:08 PM | Tags: None
Filtering items from a container is a common situation. Bartłomiej Filipek demonstrates various approaches from different versions of C++.
15 Different Ways to Filter Containers in Modern C++
by Bartłomiej Filipek
From the article:
Do you know how many ways we can implement a filter function in C++? While the problem is relatively easy to understand – take a container, copy elements that match a predicate and the return a new container – it’s good to exercise with the C++ Standard Library and check a few ideas. We can also apply some modern C++ techniques, including C++23. Let’s start!
The problem statement
To be precise by a filter, I mean a function with the following interface:
auto Filter(const Container& cont, UnaryPredicate p) {}It takes a container and a predicate, and then it creates an output container with elements that satisfy the predicate. We can use it like the following:
const std::vector<std::string> vec{ "Hello", "**txt", "World", "error", "warning", "C++", "****" }; auto filtered = Filter(vec, [](auto& elem) { return !elem.starts_with('*'); }); // filtered should have "Hello", "World", // "error", "warning", "C++"Writing such a function can be a good exercise with various options and algorithms in the Standard Library. What’s more, our function hides internal things like iterators, so it’s more like a range-based version.
By Blog Staff | Feb 13, 2026 04:05 PM | Tags: None
Coroutines are powerful but require some boilerplate code. Quasar Chunawala explains what you need to implement to get coroutines working.
Coroutines – A Deep Dive
by Quasar Chunawala
From the article:
Following on from the introduction in the editorial, let’s understand the basic mechanics needed to code up a simple coroutine, and I’ll show you how to yield from the coroutine and await results.
The simplest coroutine
The following code is the simplest implementation of a coroutine:
#include <coroutine> void coro_func(){ co_return; } int main(){ coro_func(); }Our first coroutine will just return nothing. It will not do anything else. Sadly, the preceding code is too simple for a functional coroutine and it will not compile. When compiling with gcc 15.2, we get the error shown in Figure 1.
Looking at C++ reference, we see that the return type of a coroutine must define a type named
<source>: In function 'void coro_func()': <source>:4:5: error: unable to find the promise type for this coroutine 4 | co_return; | ^~~~~~~~~promise_type. Why do we need a promise? Thepromise_typeis the second important piece in the coroutine mechanism. We can draw an analogy from futures and promises which are essential blocks for achieving asynchronous programming in C++. The future is the thing, that the function that does the asynchronous computation, hands out back to the caller, that the caller can use to retrieve the result by invoking theget()member function. The future has the role of the return object.
By Blog Staff | Feb 4, 2026 04:02 PM | Tags: None
Concurrency has many different approaches. Lucian Radu Teodorescu clarifies terms, showing how different approaches solve different problems.
Concurrency Flavours
by Lucian Radu Teodorescu
From the article:
Most engineers today use concurrency – often without a clear understanding of what it is, why it’s needed, or which flavour they’re dealing with. The vocabulary around concurrency is rich but muddled. Terms like parallelism, multithreading, asynchrony, reactive programming, and structured concurrency are regularly conflated – even in technical discussions.
This confusion isn’t just semantic – it leads to real-world consequences. If the goal behind using concurrency is unclear, the result is often poor concurrency – brittle code, wasted resources, or systems that are needlessly hard to reason about. Choosing the right concurrency strategy requires more than knowing a framework or following a pattern – it requires understanding what kind of complexity you’re introducing, and why.
To help clarify this complexity, the article aims to map out some of the main flavours of concurrency. Rather than defining terms rigidly, we’ll explore the motivations behind them – and the distinct mindsets they evoke. While this article includes a few C++ code examples (using features to be added in C++26), its focus is conceptual – distinguishing between the flavours of concurrency. Our goal is to refine the reader’s taste for concurrency.
By Blog Staff | Jan 27, 2026 03:54 PM | Tags: None
Value semantics is a way of structuring programs around what values mean, not where objects live, and C++ is explicitly designed to support this model. In a value-semantic design, objects are merely vehicles for communicating state, while identity, address, and physical representation are intentionally irrelevant.
Exclusive state access, I
by Andrzej Krzemieński
From the article:
Value semantics is a way of organizing your programs, which C++ supports and endorses. Its key characteristics in a nutshell:
- Throughout its lifetime an object (via its type and special member functions) is used to represent a value.
- Different parts of the program communicate values via objects. While the value matters, objects themselves (their address, their
sizeof) do not.- Object’s value is isolated from other objects’ values.
This begs the question, what is value, but we will not answer it. First, because it is difficult, and maybe impossible. It is pretty clear what value objects of type
intrepresent. It is fairly uncontroversial what value is represented byvector<int>, once we accept that the value representation need not fit into thesizeofof the object, but can spread across other memory locations and resources, and that vector’s capacity is not part of this value, even though it is part of its state. But there are things likestd::mutexwhere naming the value is tricky.
By Blog Staff | Jan 21, 2026 11:20 AM | Tags: None
In today's post, I like to touch on a controversial topic: singletons. While I think it is best to have a codebase without singletons, the real-world shows me that singletons are often part of codebases.
Singleton done right in C++
by Andreas Fertig
From the article:
Let's use a usage pattern for a singleton that I see frequently, a system-wide logger. A simple implementation can look like the following code:
class Logger {
Logger() = default;public:
static Logger& Instance()
{
static Logger theOneAndOnlyLogger{};return theOneAndOnlyLogger;
}void Info(std::string_view msg) { std::print("Info: {}", msg); }
void Error(std::string_view msg) { std::print("Error: {}", msg); }
};The key parts for a singleton in C++ are that the constructor is private and an access function that is static. With that, you ensure that a singleton object, here Logger can only be constructed by calling Instance, essentially limiting the number of Logger objects to a single one.
You're using such a Logger like this:
Logger::Instance().Info("A test");
By jdgarcia | Jan 17, 2026 10:12 AM | Tags: None
Once more the using std::cpp conference is here and they bring two interesting training workshops.
Both workshops happen in the post-conference day on March 19th in Madrid.
You may also want to have a look to the list of speakers for the main conference.
If you are one of the first 20 attendees to each workshops, your are eligible for a free ticket for the main conference.
By Blog Staff | Jan 15, 2026 11:14 AM | Tags: None

Templates and metaprogramming considered as the big bad wolf of C++, and it’s time to stop being scared of this wolf, as it’s one of the most powerful creatures of C++.
Talk: Who’s Afraid of the Big Bad Template
by Coral Kashri
From the description:
In this talk I’ve demonstrated the power of this incredible creature, while I hope that this talk would be an easy enterence to this concept (pan intended), and to help you developing the anticipation to walk into the cave of metaprogramming.
The talk was give on Core C++ 2025.
By Blog Staff | Jan 15, 2026 11:14 AM | Tags: None

Templates and metaprogramming considered as the big bad wolf of C++, and it’s time to stop being scared of this wolf, as it’s one of the most powerful creatures of C++.
Talk: Who’s Afraid of the Big Bad Template
by Coral Kashri
From the description:
In this talk I’ve demonstrated the power of this incredible creature, while I hope that this talk would be an easy enterence to this concept (pan intended), and to help you developing the anticipation to walk into the cave of metaprogramming.
The talk was give on Core C++ 2025.