g...@wolfgang-ehrhardt.de wrote:
Zitat von Adriaan van Os :
Even with masked exceptions, runtime errors are produced in the Math
unit. That is not conformant to the standard.
Even with masked exInvalidOp? Can you give an example?
Math.power with a negative base would except, even with maske
Zitat von James Richters :
The fact that it raises the exception at all makes it a signaling
NaN not a quiet Nan, but they are supposed to be Quiet Nan which
never throw the exception according to the specification which
clearly states they are Quiet Nans, not Signaling Nans.
Suppressi
discussions
Subject: Re: [fpc-pascal] math with infinity and NaN
Zitat von James Richters :
>> 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 provi
Zitat von James Richters :
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 mea
-
From: fpc-pascal [mailto:fpc-pascal-boun...@lists.freepascal.org] On Behalf Of
g...@wolfgang-ehrhardt.de
Sent: Thursday, June 21, 2018 2:46 AM
To: FPC-Pascal users discussions
Subject: Re: [fpc-pascal] math with infinity and NaN
Quoting James Richters :
> SetExceptionMask(GetExceptionM
0, 2018 3:42 AM
To: fpc-pascal@lists.freepascal.org
Subject: Re: [fpc-pascal] math with infinity and NaN
This is compatible with IEEE-754. Section 7.2 says
7.2 Invalid operation
For operations producing results in floating-point format, the default result
of an operation that signals the invalid
Zitat von Adriaan van Os :
Even with masked exceptions, runtime errors are produced in the Math
unit. That is not conformant to the standard.
Even with masked exInvalidOp? Can you give an example?
___
fpc-pascal maillist - fpc-pascal@lists.freepa
Florian Klämpfl wrote:
Am 20.06.2018 um 10:59 schrieb Adriaan van Os:
James Richters wrote:
I’ve been updating my old programs to use the MATH unit in
freepascal and while testing things I came across a runtime error
217 Invalid floating point operation. Here is my test program
I su
Quoting James Richters :
SetExceptionMask(GetExceptionMask + [exInvalidOp]); Works!
Thank you for the help!
I'm curious why things like SQRT(-1) just produce NAN without
needing to change the exception mask and (+inf) - (+inf) does not
behave the same way. They both are invalid,
Zitat von C Western :
My first reaction is that
SetExceptionMask([exDenormalized,exZeroDivide,exOverflow,exUnderflow,exPrecision])
would be required (I can't remember what the default is), but it
doesn't stop the error (x86_64/linux). I suspect a bug, though I am
slightly surprised it hasn'
This is compatible with IEEE-754. Section 7.2 says
7.2 Invalid operation
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)
ssage-
From: fpc-pascal [mailto:fpc-pascal-boun...@lists.freepascal.org] On Behalf Of
Sven Barth via fpc-pascal
Sent: Wednesday, June 20, 2018 5:23 PM
To: fpc-pascal@lists.freepascal.org
Cc: Sven Barth
Subject: Re: [fpc-pascal] math with infinity and NaN
Am 20.06.2018 um 23:15 schrieb James Ric
On 20/06/18 22:16, C Western wrote:
On 20/06/18 21:58, Florian Klämpfl wrote:
Am 19.06.2018 um 23:50 schrieb James Richters:
I’ve been updating my old programs to use the MATH unit in freepascal
and while testing things I came across a runtime error 217 Invalid
floating point operation. Here
Am 20.06.2018 um 23:15 schrieb James Richters:
Is there a way to prevent getting the runtime error?
=== code begin ===
SetExceptionMask(GetExceptionMask + [exInvalidOp]);
=== code end ===
Regards,
Sven
___
fpc-pascal maillist - fpc-pascal@lists.f
On 20/06/18 21:58, Florian Klämpfl wrote:
Am 19.06.2018 um 23:50 schrieb James Richters:
I’ve been updating my old programs to use the MATH unit in freepascal
and while testing things I came across a runtime error 217 Invalid
floating point operation. Here is my test program
Uses math;
var
>Please read the standard, exceptions are part of it.
Not much of a 'standard' if it's full of exceptions so everyone just does it
however they want and therefore nothing is actually standard.
___
fpc-pascal maillist - fpc-pascal@lists.freepascal.org
Is there a way to prevent getting the runtime error?
James
-Original Message-
From: fpc-pascal [mailto:fpc-pascal-boun...@lists.freepascal.org] On Behalf Of
Florian Klämpfl
Sent: Wednesday, June 20, 2018 4:59 PM
To: fpc-pascal@lists.freepascal.org
Subject: Re: [fpc-pascal] math with
Am 20.06.2018 um 10:59 schrieb Adriaan van Os:
James Richters wrote:
I’ve been updating my old programs to use the MATH unit in freepascal and while testing things I came across a runtime
error 217 Invalid floating point operation. Here is my test program
I suggest to file a bug report. I
Am 19.06.2018 um 23:50 schrieb James Richters:
I’ve been updating my old programs to use the MATH unit in freepascal and while testing things I came across a runtime
error 217 Invalid floating point operation. Here is my test program
Uses math;
var
variable1:double;
variable2:doubl
manity.com/Infinity_Minus_Infinity.html
James
-Original Message-
From: fpc-pascal [mailto:fpc-pascal-boun...@lists.freepascal.org] On Behalf Of
Marco van de Voort
Sent: Wednesday, June 20, 2018 9:21 AM
To: FPC-Pascal users discussions
Subject: Re: [fpc-pascal] math with infinity and NaN
In our previo
In our previous episode, C Western said:
> > I can do things like +infinity*2 and +infinity-3 and even sqr(infinity)
> > and power(infinity,10) the results are still +Inf which is expected?
> > ??but I can?t do anything involving subtracting infinity from
> > infinity.?
Isn't that normal? Oth
James Richters wrote:
I’ve been updating my old programs to use the MATH unit in freepascal
and while testing things I came across a runtime error 217 Invalid
floating point operation. Here is my test program
I suggest to file a bug report. It is very unfortunate that the Math unit
doesn
On 19/06/18 22:50, James Richters wrote:
I’ve been updating my old programs to use the MATH unit in freepascal
and while testing things I came across a runtime error 217 Invalid
floating point operation. Here is my test program
Uses math;
var
variable1:double;
variable2:double;
B
23 matches
Mail list logo