diff options
author | vlefevre <vlefevre@280ebfd0-de03-0410-8827-d642c229c3f4> | 2017-05-15 15:19:11 +0000 |
---|---|---|
committer | vlefevre <vlefevre@280ebfd0-de03-0410-8827-d642c229c3f4> | 2017-05-15 15:19:11 +0000 |
commit | 0b70dc273fcd2c8d530d6e66e175bee5b1239cc0 (patch) | |
tree | af8154dbfbfb3d0ac552a23644b66f0ffdf32161 /src/mpfr-impl.h | |
parent | 418c08a8c3dda5d97e5e2995e336364f99485e20 (diff) | |
download | mpfr-0b70dc273fcd2c8d530d6e66e175bee5b1239cc0.tar.gz |
Do not define macro names starting with "SIG" (+ uppercase letter)
as they are reserved when <signal.h> is included (ISO C, 7.31.7),
which happens to be the case in tests/tests.c, which also includes
tests/mpfr-test.h and src/mpfr-impl.h indirectly.
* src/mpfr-impl.h, tests/mpfr-test.h: renamed macros:
SIGN → VSIGN
SIGN_RAND → RAND_SIGN
* {src,tests}/*.{c,h}: updated the names in the use of these macros.
git-svn-id: svn://scm.gforge.inria.fr/svn/mpfr/trunk@11476 280ebfd0-de03-0410-8827-d642c229c3f4
Diffstat (limited to 'src/mpfr-impl.h')
-rw-r--r-- | src/mpfr-impl.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/mpfr-impl.h b/src/mpfr-impl.h index b39e2edfa..a993a85d1 100644 --- a/src/mpfr-impl.h +++ b/src/mpfr-impl.h @@ -1012,8 +1012,9 @@ typedef uintmax_t mpfr_ueexp_t; (I) != 0 ? ((__gmpfr_flags |= MPFR_FLAGS_INEXACT), (I)) : 0 #define MPFR_RET_NAN return (__gmpfr_flags |= MPFR_FLAGS_NAN), 0 -#define SIGN(I) ((I) < 0 ? -1 : (I) > 0) -#define SAME_SIGN(I1,I2) (SIGN (I1) == SIGN (I2)) +/* Sign of a native value. */ +#define VSIGN(I) ((I) < 0 ? -1 : (I) > 0) +#define SAME_SIGN(I1,I2) (VSIGN (I1) == VSIGN (I2)) /****************************************************** |