[Bug preprocessor/7263] __extension__ keyword doesn't suppress warning on LL or ULL constants

dodji at gcc dot gnu dot org gcc-bugzilla@gcc.gnu.org
Fri Jun 4 19:37:00 GMT 2010



------- Comment #25 from dodji at gcc dot gnu dot org  2010-06-04 19:36 -------
Created an attachment (id=20846)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=20846&action=view)
Fixes all regressions of C FE's testsuite

This update fixes all the regressions I have noticed in the test suite of the C
FE. I have done the testing and debugging with bootstrap disabled.

This patch merges Tom's initial patch and my additions and should apply to
recent trunk.

Next step is to bootstrap the C FE and see/fix the remaining bugs that I
encounter there.

Here is what the patch does at the moment:

$ cat test.c
     1  #define OPERATE(OPRD1, OPRT, OPRD2) \
     2   OPRD1 OPRT OPRD2;
     3
     4  #define SHIFTL(A,B) \
     5    OPERATE (A,<<,B)
     6
     7  #define MULT2(A) \
     8    SHIFTL (A,1)
     9
    10  void
    11  g ()
    12  {
    13    MULT2 (1.0);/* 1.0 << 1;*/
    14  }

$ ./cc1 -quiet test.c
While expanding macro OPERATE at test.c:2:8
While expanding macro SHIFTL at test.c:5:14
While expanding macro MULT2 at test.c:8:3
test.c: In function 'g':
test.c:13:3: error: invalid operands to binary << (have 'double' and 'int')


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=7263



More information about the Gcc-bugs mailing list