turbo-C and lint ?

D'Arcy J.M. Cain darcy at druid.uucp
Mon Mar 26 02:30:15 AEST 1990


In article <1964 at bruce.OZ> alanf at bruce.OZ (Alan Grant Finlay) writes:
>I was surprised to discover that the Turbo-C package does not come with a lint
>program.  Specifically I want to have the ability to automatically check for
>procedure argument type consistency.  When in the past I have complained to
>C advocates that C compilers don't check for consistent use of parameters they
>have usually replied "that's what lint is for!".  Is it really acceptable for
>a commercial compiler package to come supplied without an essential part or
>have I missed something in the package that does the same job?
>
>Also does anyone know if there are any public domain lints available that will
>work with Turbo-C source?

In Turbo-C (2.0 at least) lint is effectively built in.  As long as the
functions are prototyped (and this is true for all of their library functions
if you include the proper header files) then you can be warned of all these
sorts of things.  You must turn on the warnings with a switch but these
can be turned on as a default in your configuration file.  I think that
this type of checking is true for all compilers that try to be ANSI compliant.
That is the point of prototyping - to be able to check each call for errors.

-- 
D'Arcy J.M. Cain (darcy at druid)     |   Thank goodness we don't get all 
D'Arcy Cain Consulting             |   the government we pay for.
West Hill, Ontario, Canada         |
(416) 281-6094                     |



More information about the Comp.lang.c mailing list