]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
system.h (IN_RANGE): Cast each argument individually.
authorRichard Sandiford <rsandifo@nildram.co.uk>
Sun, 21 Oct 2007 10:47:22 +0000 (10:47 +0000)
committerRichard Sandiford <rsandifo@gcc.gnu.org>
Sun, 21 Oct 2007 10:47:22 +0000 (10:47 +0000)
gcc/
* system.h (IN_RANGE): Cast each argument individually.

From-SVN: r129531

gcc/ChangeLog
gcc/system.h

index b2356a6eb04452d42131b45c4c767a4524abae9a..bab23e50dd4bf6dc5e06863ff307c10e97eff5dc 100644 (file)
@@ -1,3 +1,7 @@
+2007-10-21  Richard Sandiford  <rsandifo@nildram.co.uk>
+
+       * system.h (IN_RANGE): Cast each argument individually.
+
 2007-10-21  Richard Sandiford  <rsandifo@nildram.co.uk>
 
        * config/mips/mips.c (mips_set_mips16_mode) Say sorry for hard-float
index 1696b9c92b496aca456cd4a298bcd46bf65b6501..65f27379ad118087d1743806831d0457c1085417 100644 (file)
@@ -253,7 +253,8 @@ extern int errno;
    UPPER.  However the bounds themselves can be either positive or
    negative.  */
 #define IN_RANGE(VALUE, LOWER, UPPER) \
-  ((unsigned HOST_WIDE_INT)((VALUE) - (LOWER)) <= ((UPPER) - (LOWER)))
+  ((unsigned HOST_WIDE_INT) (VALUE) - (unsigned HOST_WIDE_INT) (LOWER) \
+   <= (unsigned HOST_WIDE_INT) (UPPER) - (unsigned HOST_WIDE_INT) (LOWER))
 
 /* Infrastructure for defining missing _MAX and _MIN macros.  Note that
    macros defined with these cannot be used in #if.  */