volatile and Other Small Improvements in C++20
/
0 Comments
Today, I complete my tour through the C++20 core language features with a few small improvements. One…
New Attributes with C++20
With C++20, we got new and improved attributes such as [[nodiscard("reason")]], [[likely]], [[unlikely]],…
More Lambda Features with C++20
Lambdas in C++20 can be default-constructed and support copy-assignment when they have no state. Lambdas…
More Powerful Lambdas with C++20
Thanks to C++20, lambdas have become more powerful. From the various lambda improvements, template parameters…
Various Template Improvements with C++20
Admittedly, I present in this post a few minor improvements to templates and C++20 in general. Although…
Solving the Static Initialization Order Fiasco with C++20
According to the FAQ of isocpp.org is the static initialization order fiasco "a subtle way to crash…
Two new Keywords in C++20: consteval and constinit
With C++20, we get two new keywords: consteval and constinit. consteval produces a function executed…
Designated Initializers
Designated initialization is an extension of aggregate initialization and empowers you to directly initialize…
C++20: Optimized Comparison with the Spaceship Operator
In this post, I conclude my miniseries on the three-way comparison operator with a few subtle details.…
C++20: More Details to the Spaceship Operator
The compiler performs cleverly when it generates all six comparison operators. Ultimately, you get intuitive…