summaryrefslogtreecommitdiff
path: root/tests/tsub1sp.c
diff options
context:
space:
mode:
authorvlefevre <vlefevre@280ebfd0-de03-0410-8827-d642c229c3f4>2017-05-04 09:40:05 +0000
committervlefevre <vlefevre@280ebfd0-de03-0410-8827-d642c229c3f4>2017-05-04 09:40:05 +0000
commitaf5a1593331d686b9cc5fbbbbdc47e1733a4644e (patch)
treeff8210e41ae8ced432dbcd42e8be2a919f8dddc6 /tests/tsub1sp.c
parent87ff38458263c9a9ed79a7ebd547fd32a66ae843 (diff)
parentd79a8111e6b7851b15bac211d8dca0e67a2979b5 (diff)
downloadmpfr-af5a1593331d686b9cc5fbbbbdc47e1733a4644e.tar.gz
Merged the latest changes from the trunk, including some old changesets
related to mpfr_zeta that were skipped, resolving conflicts. Added RNDF support to new code introduced by this merge: * mpfr_mul_1n in src/mul.c (from r11281); * mpfr_sqr_1n in src/sqr.c (from r11283); * mpfr_div_1n in src/div.c (from r11284); * mpfr_sqrt1n in src/sqrt.c (from r11293). git-svn-id: svn://scm.gforge.inria.fr/svn/mpfr/branches/faithful@11456 280ebfd0-de03-0410-8827-d642c229c3f4
Diffstat (limited to 'tests/tsub1sp.c')
-rw-r--r--tests/tsub1sp.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/tsub1sp.c b/tests/tsub1sp.c
index 52ec3398a..bace43931 100644
--- a/tests/tsub1sp.c
+++ b/tests/tsub1sp.c
@@ -167,7 +167,7 @@ compare_sub_sub1sp (void)
mpfr_prec_t p;
unsigned long d;
int i, inex_ref, inex;
- mpfr_rnd_t r;
+ int r;
for (p = 1; p <= 3*GMP_NUMB_BITS; p++)
{
@@ -194,14 +194,14 @@ compare_sub_sub1sp (void)
{
/* increase the precision of b to ensure sub1sp is not used */
mpfr_prec_round (b, p + 1, MPFR_RNDN);
- inex_ref = mpfr_sub (a_ref, b, c, r);
+ inex_ref = mpfr_sub (a_ref, b, c, (mpfr_rnd_t) r);
inex = mpfr_prec_round (b, p, MPFR_RNDN);
MPFR_ASSERTN(inex == 0);
- inex = mpfr_sub1sp (a, b, c, r);
+ inex = mpfr_sub1sp (a, b, c, (mpfr_rnd_t) r);
if (inex != inex_ref)
{
printf ("mpfr_sub and mpfr_sub1sp differ for r=%s\n",
- mpfr_print_rnd_mode (r));
+ mpfr_print_rnd_mode ((mpfr_rnd_t) r));
printf ("b="); mpfr_dump (b);
printf ("c="); mpfr_dump (c);
printf ("expected inex=%d and ", inex_ref);