summaryrefslogtreecommitdiff
path: root/src/sqr.c
diff options
context:
space:
mode:
authorPhilippe Theveny <philippe.theveny@laposte.net>2009-04-23 10:44:04 +0000
committerPhilippe Theveny <philippe.theveny@laposte.net>2009-04-23 10:44:04 +0000
commit38107cc593f7ddaac345899f21bc27c0f534d6ae (patch)
tree991e8b91ebe80ef5a3b0c84dea86b1d6ce4d9286 /src/sqr.c
parente601852e38e3510889c3a320136fc988d6d5a9a7 (diff)
downloadmpc-git-38107cc593f7ddaac345899f21bc27c0f534d6ae.tar.gz
src/sqr.c: Add parenthesis around condition (avoid a gcc 4.4.0 warning).
git-svn-id: svn+ssh://scm.gforge.inria.fr/svnroot/mpc/trunk@539 211d60ee-9f03-0410-a15a-8952a2c7a4e4
Diffstat (limited to 'src/sqr.c')
-rw-r--r--src/sqr.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/sqr.c b/src/sqr.c
index ac4b15f..3977742 100644
--- a/src/sqr.c
+++ b/src/sqr.c
@@ -159,7 +159,7 @@ mpc_sqr (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
else if (mpfr_sgn (u) * mpfr_sgn (v) > 0)
{
inexact |= mpfr_mul (u, u, v, GMP_RNDU); /* error 5 */
- ok = !inexact | mpfr_can_round (u, prec - 3, GMP_RNDU, GMP_RNDZ,
+ ok = (!inexact) | mpfr_can_round (u, prec - 3, GMP_RNDU, GMP_RNDZ,
MPFR_PREC (MPC_RE (rop)) + (MPC_RND_RE (rnd) == GMP_RNDN));
if (ok)
{
@@ -172,7 +172,7 @@ mpc_sqr (mpc_ptr rop, mpc_srcptr op, mpc_rnd_t rnd)
else
{
inexact |= mpfr_mul (u, u, v, GMP_RNDD); /* error 5 */
- ok = !inexact | mpfr_can_round (u, prec - 3, GMP_RNDD, GMP_RNDZ,
+ ok = (!inexact) | mpfr_can_round (u, prec - 3, GMP_RNDD, GMP_RNDZ,
MPFR_PREC (MPC_RE (rop)) + (MPC_RND_RE (rnd) == GMP_RNDN));
if (ok)
{