summaryrefslogtreecommitdiff
path: root/get_z.c
diff options
context:
space:
mode:
authorvlefevre <vlefevre@280ebfd0-de03-0410-8827-d642c229c3f4>2009-04-08 14:25:26 +0000
committervlefevre <vlefevre@280ebfd0-de03-0410-8827-d642c229c3f4>2009-04-08 14:25:26 +0000
commit25fb56d8f56bee9ff1341da83eea9b853b453eae (patch)
tree0f1ac2bf2c0301ae778797ec6e328a0fc29f4e34 /get_z.c
parent48fe6389b93c38f978512b84d3a470d74c470ec4 (diff)
downloadmpfr-25fb56d8f56bee9ff1341da83eea9b853b453eae.tar.gz
tests/tget_z.c: do not assume specific values of the ternary value.
get_z.c: simplified code. git-svn-id: svn://scm.gforge.inria.fr/svn/mpfr/trunk@6157 280ebfd0-de03-0410-8827-d642c229c3f4
Diffstat (limited to 'get_z.c')
-rw-r--r--get_z.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/get_z.c b/get_z.c
index 7898f746c..e158a98cd 100644
--- a/get_z.c
+++ b/get_z.c
@@ -44,6 +44,6 @@ mpfr_get_z (mpz_ptr z, mpfr_srcptr f, mp_rnd_t rnd)
else
mpz_div_2exp (z, z, -exp);
mpfr_clear (r);
-
- return inex == 2 ? 1 : inex == -2 ? -1 : 0;
+
+ return inex;
}