summaryrefslogtreecommitdiff
path: root/tests/tests.c
diff options
context:
space:
mode:
Diffstat (limited to 'tests/tests.c')
-rw-r--r--tests/tests.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/tests.c b/tests/tests.c
index f81ac0e6e..a7525e8f5 100644
--- a/tests/tests.c
+++ b/tests/tests.c
@@ -545,7 +545,7 @@ test5rm (int (*fct) (FLIST), mpfr_srcptr x, mpfr_ptr y, mpfr_ptr z,
{
MPFR_ASSERTN (rnd != MPFR_RND_MAX);
fct (z, x, rnd);
- if (! mpfr_equal_p (y, z))
+ if (! (mpfr_equal_p (y, z) || (mpfr_nan_p (y) && mpfr_nan_p (z))))
{
printf ("Error for %s with xprec=%lu, yprec=%lu, rnd=%s\nx = ",
name, (unsigned long) MPFR_PREC (x), (unsigned long) yprec,