This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

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



------- Comment #30 from manu at gcc dot gnu dot org  2010-06-09 17:57 -------
(In reply to comment #29)
> Created an attachment (id=20878)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=20878&action=view) [edit]
> Refreshed version. Fully Bootstraps the C FE and passes regression tests.
> 
> This fixes a annoying bug that were making the compiler emit wrong debug info,
> leading to binaries that were not really debug-able.
> 
> Next stop is to disable this feature by default, and enable it with a
> -ftrack-macro-expansion flag, and update the regressions tests of the C FE.

Great but... you should just prune the output in the general case (extending
prune.exp) and only bother to handle the extra output in cases where it makes
sense to specifically test it. This is what we do for the "inlined from"
messages and it makes sense to do the same for this kind of message.

I see now the sense in the column numbers, I think it is the order that
confused me (and not seeing the code clearly). I would prefer a different
output like:

test.c:13:3: in expansion of macro MULT2
test.c:5:14: in expansion of macro SHIFTL
test.c:8:3: in expansion of macro OPERATE
test.c:2:8: error: invalid operands to binary << (have 'double' and 'int')

But this is bike-shedding at this stage and it is more important to get the
internals working.

BTW, do we also keep the information about the macro arguments? If so, after
your patch goes in we could even go as far as to print macro arguments:

test.c:13:3: in expansion of macro MULT2 [with A=1.0]
test.c:5:14: in expansion of macro SHIFTL [with A=1.0, B=1]
test.c:8:3: in expansion of macro OPERATE [with OPRD1=1.0, OPTR=<<, OPTRD2=1]
test.c:2:8: error: invalid operands to binary << (have 'double' and 'int')

Ok, ok. let's get back to reality ;-)


-- 


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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]