[splint-discuss] Parse error with pthread
cbfalconer at yahoo.com
Tue Aug 3 23:38:30 EDT 2004
"Sekuri, Yaminikrishna (GE Consumer & Industrial)" wrote:
> I am using SPLINT to check my code for ANSI compliance.
> I get the Parser error with respect to pthreads.
> My source code file source.c includes a file xyz.h which in turn
> has pthread_t structure and a function which return this structure.
> When I try doing ./splint source.c,
> I get the following parse error:
> In file included from source.c:45
> Parse Error. (For help on parse errors, see splint -help parseerrors.)
> *** Cannot continue.
> Can anyone suggest what has to be done to overcome this parse
You are trying to verify system headers, which need not be
standard. Check your environment settins for larch_path and
include *during splint execution*.
At any rate, this is misuse of splint. Your compiler is intended
to detect all syntax errors, and pass all correct syntax. Splint
is intended to warn about all suspicious usage. You would be
better advised to check syntax with:
gcc -W -Wall -ansi -pedantic -Wwrite-strings -gstabs+ -O1
(I have an alias set so that is used routinely) Replace -ansi
with -std=C99 if desired.
"I'm a war president. I make decisions here in the Oval Office
in foreign policy matters with war on my mind." - Bush.
"Churchill and Bush can both be considered wartime leaders, just
as Secretariat and Mr Ed were both horses." - James Rhodes.
More information about the splint-discuss