lint and #include a static
Jim
ix269 at sdccs6.UUCP
Sat Jul 21 18:50:55 AEST 1984
(doe static attract lint ? :-)
+=+=+=+=+=+=+ lint tmp.c +=+=+=+=+=+=+
tmp.c:
tmp.c(3): redeclaration of abc
abc defined( ./tmp.h(1) ), but never used
+=+=+=+=+=+=+=+ tmp.h +=+=+=+=+=+=+=+
static int abc;
+=+=+=+=+=+=+=+ tmp.c +=+=+=+=+=+=+=+
#include "tmp.h"
abc = 1;
main()
{
abc = 2;
printf("%d\n",abc);
}
/* Here is an answer to the question about a nasty little bit
* about static variables being static to a file, yes but no.
* The variable is available for use, but not in any routine in
* the file.
*/
-----
Jim
{dcdwest,ucbvax}!sdcsvax!sdccs6!ix269
More information about the Comp.lang.c
mailing list