[PATCH] fix warning about duplicate 'const'
Paul Koning
pkoning@equallogic.com
Wed Mar 10 18:35:00 GMT 2004
>>>>> "Andrew" == Andrew Haley <aph@redhat.com> writes:
Andrew> Richard Henderson writes:
>> On Wed, Mar 10, 2004 at 07:43:10AM -0800, Linus Torvalds wrote: >
>> Ok, let's try just stripping the "const" out of the min/max
>> macros, and > see what complains.
>>
>> I remember what complains. You get actual errors from
>>
>> const int x; int y; min(x, y);
Andrew> Can you explain *why* we have to produce a diagnostic for
Andrew> "const const int" by default?
Andrew> Can't we dispatch such things to "-pedantic" ?
I like that suggestion.
paul
More information about the Gcc
mailing list