summaryrefslogtreecommitdiff
path: root/tests/terf.c
diff options
context:
space:
mode:
authorpelissip <pelissip@280ebfd0-de03-0410-8827-d642c229c3f4>2003-11-21 15:27:35 +0000
committerpelissip <pelissip@280ebfd0-de03-0410-8827-d642c229c3f4>2003-11-21 15:27:35 +0000
commit41d7b44241b63a451c3e664bdd9a640a4c255291 (patch)
tree6a82613a3cf86ab03825e93e2987ad51e8ab58a6 /tests/terf.c
parent1cd11b42766c57e2118aac4ffe5219fac353904d (diff)
downloadmpfr-41d7b44241b63a451c3e664bdd9a640a4c255291.tar.gz
+ Add new internal function: mpfr_check.
+ Add the corresponding test file. + Translate mpfr_set_d to mpfr_set_str / mpfr_set_ui in the tests for portability reasons. git-svn-id: svn://scm.gforge.inria.fr/svn/mpfr/trunk@2562 280ebfd0-de03-0410-8827-d642c229c3f4
Diffstat (limited to 'tests/terf.c')
-rw-r--r--tests/terf.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/terf.c b/tests/terf.c
index 64c1cca72..4cf98821e 100644
--- a/tests/terf.c
+++ b/tests/terf.c
@@ -86,7 +86,7 @@ main (int argc, char *argv[])
exit (1);
}
- mpfr_set_d (x, 1.0, GMP_RNDN);
+ mpfr_set_ui (x, 1, GMP_RNDN);
mpfr_erf (x, x, GMP_RNDN);
mpfr_set_str_binary (y, "0.11010111101110110011110100111010000010000100010001011");
if (mpfr_cmp (x, y))
@@ -101,7 +101,7 @@ main (int argc, char *argv[])
exit (1);
}
- mpfr_set_d (x, 6.6, GMP_RNDN);
+ mpfr_set_str (x, "6.6", 10, GMP_RNDN);
mpfr_erf (x, x, GMP_RNDN);
if (mpfr_cmp_ui (x, 1))
{
@@ -113,7 +113,7 @@ main (int argc, char *argv[])
exit (1);
}
- mpfr_set_d (x, 6.6, GMP_RNDN);
+ mpfr_set_str (x, "6.6", 10, GMP_RNDN);
mpfr_erf (x, x, GMP_RNDZ);
mpfr_set_str_binary (y, "0.11111111111111111111111111111111111111111111111111111");
if (mpfr_cmp (x, y))
@@ -128,7 +128,7 @@ main (int argc, char *argv[])
exit (1);
}
- mpfr_set_d (x, 4.5, GMP_RNDN);
+ mpfr_set_str (x, "4.5", 10, GMP_RNDN);
mpfr_erf (x, x, GMP_RNDN);
mpfr_set_str_binary (y, "0.1111111111111111111111111111111100100111110100011");
if (mpfr_cmp (x, y))