diff options
-rw-r--r-- | test/test-floatingpoint.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/test/test-floatingpoint.c b/test/test-floatingpoint.c index 66d84411..febfae05 100644 --- a/test/test-floatingpoint.c +++ b/test/test-floatingpoint.c @@ -21,7 +21,9 @@ int main(void) { /* 15 + 1/2 + 1/8 = 15.625 */ /* 15 + 1/2 + 1/8 + 1/32 = 15.65625 */ /* 15 + 1/2 + 1/8 + 1/32 + 1/128 = 15.6640625 */ - if ((-*magic == 15.0 + 0.5 + 0.125 + 0.03125 + 0.0078125)) abort(); + if ((*magic >= 15.0 + 0.5 + 0.125 + 0.03125) && + (*magic <= 15.0 + 0.5 + 0.125 + 0.03125 + 0.0078125)) + abort(); } |