[splint-discuss] Tolerance for compiler extensions

Oliver Betz list_ob at gmx.net
Wed Sep 24 12:20:04 EDT 2003


Matthias Hawran wrote:

[I wrote some time ago]

> >and assembler blocks (#pragma asm/endasm) which are really bad for
> >the parser.
> >
> >I know how to hide these constucts from Splint but I would really
> >dislike it (see below).
> >
> 
> I read the whole thread, but i didn't find / undestand what is your
> construct to hide (#pragma asm/endasm) from splint. As i'm developping
> with embedded software compilers, it's hard to avoid this construct.

You have to put it in separate files and #include it :-( since the 
Splint parser doesn't survive the asm code.

To avoid trouble with nonstandard "embedded constructs", I strongly 
suggest to consider buying PC-Lint from Gimpel. It's not free (210EUR 
at www.kessler.de) but saves _much_ more time than it costs (if your 
work time counts)! You might search also for other messages about PC-
Lint in this mailing list.

Read the PC-Lint manual and you will find that Gimpel also doesn't 
love the embedded extensions ("Compiler writers have shown no dearth 
of creativity in their invention of new syntax" - ROFL), but is 
realistic enough to accept them instead of fighting against them.

You also might be confronted with the MISRA rules - PC-Lints checks 
most of them (as long as static code check is able to test the rule). 
Some of them are reasonable even if you are not forced to apply them.

Oliver
-- 
Oliver Betz, Muenchen




More information about the splint-discuss mailing list