[splint-discuss] Option to allow gcc mixed code/declarations

John Matthews johnm at picochip.com
Thu Jul 6 03:59:40 EDT 2006


Thanks Auguste- I appreciate that the code isn't C90. But then neither are the other gcc extensions that +gnuextensions tells splint to ignore; why not this as well?

Yes, I can modify the offending code, but there's quite a lot of it :-(

John

> The only way I got arround this is :
>
> #ifndef S_SPLINT_S
> /* Code to ignore be ignored by splint */
> #endif
>
> Splint conforms to ISO C90 which does not allow intermixed code and
> declarations. All declarations have to be at the top of a block. 
>
> That is to say : there is no way of 'telling' splint that your piece of
> code is OK because is not ISO C90; however, you can tell splint to
> ignore the corresponding line in order to avoid parse errors.
>
> Le mercredi 05 juillet 2006 à 14:25 +0100, John Matthews a écrit :
> > Hi- I'm trying to use splint to check some existing code that has
> > variable declarations within code ie. not just at the top of blocks, as
> > allowed by gcc. Is there a way of persuading splint that this is ok,
> > instead of stopping with a parse error? BTW +gnuextensions doesn't
> > help.
> > TIA
> > John
This email and any files transmitted with it are confidential and intended solely for the use of the individuals to whom they are addressed. If you have received this email in error please notify the sender and delete the message from your system immediately.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.cs.Virginia.EDU/pipermail/splint-discuss/attachments/20060706/37e8eb05/attachment.htm


More information about the splint-discuss mailing list