On Fri, 14 Feb 2020, Florian Weimer wrote:
* Jonathan Wakely:
I think it's very unlikely that constexpr support will decrease. The
trend has been in the opposite direction, to make every function in
the standard library usable in constant expressions. I heard a
suggestion to require implementations to add constexpr to <cmath>
functions just the other day.
Many of these functions depend on global state such as the rounding
mode.
So does a+b for floating point numbers.
When the user is explicitly asking for constexpr, accepting to evaluate
all those in the default rounding mode and without exceptions sounds ok.
Doing it eagerly (say when initializing a non-constexpr variable) is a
different story.
It may also depend on -frounding-math, even if the standard doesn't like
it when constexpr-ness varies.
--
Marc Glisse