Floating point rounding modes: we should restrict them slightly
Don
nospam at nospam.com
Thu Sep 10 02:35:08 PDT 2009
Rainer Deyke wrote:
> Don wrote:
>> Change the spec by adding the line to float.html:
>> "If the floating-point rounding mode is changed within a function, it
>> must be restored before the function exits.
>
> Even if that function is called 'fesetround'?
Obviously not. In fact, I'd hope to even disallow fesetround() since
it's too easy to abuse, and instead have an RAII struct to restore the
mode automatically. But that's just syntax sugar.
More information about the Digitalmars-d
mailing list