diff options
author | Marc Glisse <marc.glisse@inria.fr> | 2014-01-02 13:25:31 +0100 |
---|---|---|
committer | Marc Glisse <marc.glisse@inria.fr> | 2014-01-02 13:25:31 +0100 |
commit | 5e05d1f7516879559f504bf267cd84235ff24655 (patch) | |
tree | b5cdbcd800bff6ac476941e304fff2e8e1e916a7 /gmp-h.in | |
parent | b892dcad77d5d15b5f79e764802d33206efbc710 (diff) | |
download | gmp-5e05d1f7516879559f504bf267cd84235ff24655.tar.gz |
SHRT_MAX etc have the promoted type in standard C.
Diffstat (limited to 'gmp-h.in')
-rw-r--r-- | gmp-h.in | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -437,10 +437,10 @@ typedef __mpq_struct *mpq_ptr; #define __GMP_MAX(h,i) ((h) > (i) ? (h) : (i)) /* __GMP_USHRT_MAX is not "~ (unsigned short) 0" because short is promoted - to int by "~". */ + to int by "~". It still needs to have the promoted type. */ #define __GMP_UINT_MAX (~ (unsigned) 0) #define __GMP_ULONG_MAX (~ (unsigned long) 0) -#define __GMP_USHRT_MAX ((unsigned short) ~0) +#define __GMP_USHRT_MAX (0 + (unsigned short) ~0) /* __builtin_expect is in gcc 3.0, and not in 2.95. */ |