Closed AlexGuteniev closed 2 years ago
The use of TMPs was to implement LWG-2094, which makes overflow a SFINAE error instead of emitting diagnostics. There is no way to achieve the same thing with constexpr
functions. I think this issue cannot be fixed.
I think that if DevCom-1202945 is fixed, this still can be addressed.
Now that we can do everything in
constexpr
and haveif constexpr
, this can be expressed simpler. Probably it would improve throughput and / or readabilitySome of calculations to change to functions:
https://github.com/microsoft/STL/blob/d8f03cf399d730780b6ca0e5321a9ff4fc76bb0f/stl/inc/ratio#L51-L64