home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #27 / NN_1992_27.iso / spool / comp / os / coherent / 5820 < prev    next >
Encoding:
Text File  |  1992-11-23  |  2.2 KB  |  54 lines

  1. Newsgroups: comp.os.coherent
  2. Subject: Re: lint (was Re: various questions)
  3. Path: sparky!uunet!think.com!unixland!rmkhome!rmk
  4. From: rmk@rmkhome.UUCP (Rick Kelly)
  5. Organization: The Man With Ten Cats
  6. Date: Mon, 23 Nov 1992 16:44:49 GMT
  7. Reply-To: rmk@rmkhome.UUCP (Rick Kelly)
  8. Message-ID: <9211231144.52@rmkhome.UUCP>
  9. References: <9211211510.17@rmkhome.UUCP> <9211225585@umunk.GUN.de>
  10. Lines: 42
  11.  
  12. In article <9211225585@umunk.GUN.de> udo@umunk.GUN.de (Udo Munk) writes:
  13. >Rick Kelly (rmk@rmkhome.UUCP) wrote:
  14. >: In article <1992Nov21.014517.23226@news.weeg.uiowa.edu> jboggs@umaxc.weeg.uiowa.edu (John D. Boggs) writes:
  15. >: >
  16. >: >Okay, it's time to ask. .  .   .    .
  17. >: >
  18. >: >What, pray tell, is lint?
  19. >: 
  20. >: The stuff that you pick out of your navel when
  21. >: you have nothing else to do. :-)
  22. >
  23. >Well, a not very informative answer :-)
  24. >
  25. >Lint is a analyser for C sources. It checks function declarations
  26. >agains function calls, warns about not portable constructs,
  27. >not used variables, ignored function return values, falling
  28. >through a case switch and a lot more. The greatest advantage
  29. >(over ANSI C) is, that you can feed a whole project consist of
  30. >more then one source file, through lint. It compares the function
  31. >declaration in source file a against the function calls in
  32. >source files b, c..., and gives warnings, if arguments are of
  33. >the wrong type, or if the return value is used inconsistently.
  34. >With ANSI C the programmer has to do this work writing header
  35. >files with function prototypes. Of course there exists programs,
  36. >which creates the prototypes from an existing source.
  37. >And please: no hot discussions now about what is better, ANSI C
  38. >or K&R C + lint. Both is the same, if you have to write programs
  39. >which must be portable to older versions of UNIX use K&R C + lint,
  40. >else use ANSI C.
  41.  
  42. Lint can be helpful, but it can also get confused at times.
  43.  
  44. The Coherent 4.0 C compiler does a surprising good job of integrating
  45. some of the features of lint.
  46.  
  47. Back in the early '80s, Whitesmith C would try to compile anything.  We used
  48. to say that it would probably compile the telephone book.  Lint was a badly
  49. needed tool at that time.
  50.  
  51. -- 
  52.  
  53. Rick Kelly    rmk@rmkhome.UUCP    unixland!rmkhome!rmk    rmk@frog.UUCP
  54.