lint won't verify printf formatting against variable types??
Edward J Driscoll
ejd at caen.engin.umich.edu
Thu Jun 29 01:13:00 AEST 1989
In article <411 at isadora.ikp.liu.se>
hacker at isadora.ikp.liu.se (Goran Larsson [Hacker of Hackefors]) writes:
>In article <105 at borabora.omni.com> bob at omni.com (Bob Weissman) writes:
>>Last week I spent an entire day tracking down one of those bugs you just
>>don't see after staring at your code too long. It was of the form:
>>
>> if (condition);
>> action;
>
>>My lint (SunOS 4.0.1 version) did not flag the extra semicolon.
>
>It isn't supposed to find this "error" as it is legal C.
>
It is legal, but I would hope for a warning from such an obvious
semantic error. I don't use lint much, but Borland TC 2.0 will
warn you about some *legal* constructs like "if(x = 5)". Oddly, I
just tried it and it also lets "if(x==5);" get by without a peep.
Oh well.
>>I Hate C.
>
>I Love C
^^^^^^^^^^^---->me too
--
Ed Driscoll
The University of Michigan
ejd at caen.engin.umich.edu
More information about the Comp.lang.c
mailing list