mirror of
https://github.com/pocoproject/poco.git
synced 2025-10-28 11:31:53 +01:00
integrated some changes from GH# 249
This commit is contained in:
@@ -104,9 +104,9 @@ void FPETest::testFlags()
|
||||
// some compilers are intelligent enough to optimize the calculations below away.
|
||||
// unfortunately this leads to a failing test, so we have to trick out the
|
||||
// compiler's optimizer a little bit by doing something with the results.
|
||||
double a = 10;
|
||||
double b = 0;
|
||||
double c = div(a, b);
|
||||
volatile double a = 10;
|
||||
volatile double b = 0;
|
||||
volatile double c = div(a, b);
|
||||
|
||||
assert (FPE::isFlag(FPE::FP_DIVIDE_BY_ZERO));
|
||||
assert (FPE::isInfinite(c));
|
||||
|
||||
Reference in New Issue
Block a user