3 ms·
> I found the use of 'if constexpr' in the example pretty nasty. For new code it is to be preferred - it generates less symbols than enable_if, compiles faster
by jcelerier 7y ago
> I found the use of 'if constexpr' in the example pretty nasty.
For new code it is to be preferred - it generates less symbols than enable_if, compiles faster (by a noticeable margin from my own experience) and makes for more readable code as you don't have to go look everywhere for the various enable_if cases.