static_assert allows you to check at compile time if a type T fulfills the Concept: static_assert(Concept<T>).
In my last post "Defining Concepts with Requires Expressions", I exemplified how you can use requires expressions to define concepts. Requires expressions can also be used as a standalone feature when a compile-time predicate is required.
In my last post "Define Concepts", I defined the concepts Integral, SignedIntegral, and UnsigendIntegral using logical combinations of existing concepts and compile-time predicates. Today, I use Requires Expressions to define concepts.
Why do the biggest and most profitable trading firms use C++? In this webinar we will address this question and present one of the most anticipated features of C++20 standard: Ranges.
There are two ways to define a concept: You can combine existing concepts and compile-time predicates, or you can apply a requires expression in four different ways.
Type erasure based on templates is a pretty sophisticated technique. It allows you to bridge dynamic polymorphism (object orientation) with static polymorphism (templates).
The registration for my mentoring program, "Fundamentals for C++ Professionals", is still open until 17th April. The program starts on 22nd April.
In my last post, I presented a possible std::advance implementation based on tag dispatching. One of my readers mentioned that I could also implement std::advance based on constexpr if, or concepts. His right. So let's do it.
Before you participate in my mentoring program, you should know more about it. Today, I publish as a teaser, step six of the 28 steps to master C++.
Tag Dispatching enables it to choose a function based on the type characteristics. This decision takes place at compile time and is based on traits.
Currently are 222 guests and no members online
Kubik-Rubik Joomla! Extensions