Zitat von James Richters <ja...@productionautomation.net>:
For operations producing results in floating-point format, the
default result of an operation that
signals the invalid operation exception shall be a quiet NaN that
should provide some diagnostic
information (see 6.2).
If it shall be a quiet NaN doesn't that mean it would never cause
the runtime error? To my understating signaling NaN raises the
exception, and Quiet Nan does not.. it just quietly sets the
variable to NaN and continues by default.
It states that the DEFAULT result shall be this quiet NaN so if
that's the case then setting SetExceptionMask([exInvalidOp]); should
not be required to prevent the runtime error. The default behavior
should be that it's a Quiet NaN.
As far as I understand: if the exInvalidOp is masked the default result
is a quiet NaN. If exInvalidOp is not masked the excption is thrown.
(I do not know if a result is set to NaN and how this could be exploited).
_______________________________________________
fpc-pascal maillist - fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal