Simplifying templates and #ifdefs with if constexpr--Simon Brand

The new if constexpr will change a good part of our code for the better!

Simplifying templates and #ifdefs with if constexpr

by Simon Brand

From the article:

if constexpr is a C++17 feature which allows conditionally compiling code based on template parameters in a clear and minimal fashion. It is essentially an if statement where the branch is chosen at compile-time, and any not-taken branches are discarded without being instantiated...

Add a Comment

Comments are closed.

Comments (0)

There are currently no comments on this entry.