This is the mail archive of the gcc-patches@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]

Re: non-c89 code in bitmap.c



On Friday, June 22, 2001, at 04:35 PM, Neil Booth wrote:

> dalej@apple.com wrote:-
>
>> My understanding is that the code is supposed to be c89.  Some that
>> isn't has crept into bitmap.c recently; here is a fix.  OK?
>>
>>
>> 2001-06-22   Dale Johannesen    <dalej@apple.com>
>>
>>          * bitmap.c:  fix a non-c89 usage (null actual argument to 
>> macro)
>
> I've wondered for a while whether to get CPP to warn about this with
> -pedantic for pre-C99.  I've refrained because I think we can get too
> heavy with these warnings, and I've not yet come across a compiler
> that refuses empty arguments.  I imagine you have?
> Do you and others think this is a warning worth adding?

If I were to turn on -pedantic (which I never do), it would be because I 
was interested in strict compliance with some standard (sometimes this 
is required by contract for acceptance, for example).  Therefore, I 
would want to be warned about everything that violated that standard.  
If you see the intent of -pedantic as checking portability, rather than 
standardness, you probably wouldn't want this warning.

With our local compiler situation, as Stan explained, I personally have 
no need of a warning here:  I get an error, which is much harder to 
ignore :)


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