diff options
author | vlefevre <vlefevre@280ebfd0-de03-0410-8827-d642c229c3f4> | 2001-11-25 06:20:35 +0000 |
---|---|---|
committer | vlefevre <vlefevre@280ebfd0-de03-0410-8827-d642c229c3f4> | 2001-11-25 06:20:35 +0000 |
commit | 440570287b1a0a892422c53f6c617221d988066b (patch) | |
tree | 7cfcb4771aeae86bbb9f1fb1b5577b180b0d5a5f /mpfr-impl.h | |
parent | 6a73cc6a28ad47e4188cd5dfdfea9bb88a7b915c (diff) | |
download | mpfr-440570287b1a0a892422c53f6c617221d988066b.tar.gz |
Casts to size_t added (safer and could be required in the future).
git-svn-id: svn://scm.gforge.inria.fr/svn/mpfr/trunk@1577 280ebfd0-de03-0410-8827-d642c229c3f4
Diffstat (limited to 'mpfr-impl.h')
-rw-r--r-- | mpfr-impl.h | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/mpfr-impl.h b/mpfr-impl.h index 70e173e8d..b9b96cdb1 100644 --- a/mpfr-impl.h +++ b/mpfr-impl.h @@ -118,11 +118,14 @@ typedef union ieee_double_extract Ieee_double_extract; /* temporary allocate s limbs at xp, and initialize mpfr variable x */ #define MPFR_INIT(xp, x, p, s) \ - (xp = (mp_ptr) TMP_ALLOC((s)*BYTES_PER_MP_LIMB), \ - MPFR_PREC(x) = p, MPFR_MANT(x) = xp, MPFR_SIZE(x) = s, MPFR_EXP(x) = 0) + (xp = (mp_ptr) TMP_ALLOC((size_t) (s) * BYTES_PER_MP_LIMB), \ + MPFR_PREC(x) = (p), \ + MPFR_MANT(x) = (xp), \ + MPFR_SIZE(x) = (s), \ + MPFR_EXP(x) = 0) /* same when xp is already allocated */ #define MPFR_INIT1(xp, x, p, s) \ - (MPFR_PREC(x) = p, MPFR_MANT(x) = xp, MPFR_SIZE(x) = s) + (MPFR_PREC(x) = (p), MPFR_MANT(x) = (xp), MPFR_SIZE(x) = (s)) #ifndef _PROTO #if defined (__STDC__) || defined (__cplusplus) |