PC-Lint, Notes 964 and 966

This is a discussion on PC-Lint, Notes 964 and 966 within the Tech Board forums, part of the Community Boards category; I find these notes useful. Especially for projects with deeply nested includes. As a reminder: Originally Posted by msg.txt 964 ...

  1. #1
    (?<!re)tired Mario F.'s Avatar
    Join Date
    May 2006
    Location
    Portugal
    Posts
    7,438

    PC-Lint, Notes 964 and 966

    I find these notes useful. Especially for projects with deeply nested includes.

    As a reminder:
    Quote Originally Posted by msg.txt
    964 Header file FileName not directly used in module String -- The
    given header file was not used in the given module, however it,
    itself, included a header file (possibly indirectly) that was
    used. An example of this is os2.h that is an umbrella header
    serving only to include other headers. Compare this message with
    766. See also the discussion in §11.8.1 "Unused Headers".

    966 Indirectly included header file 'FileName' not used in module
    'String' -- The header file given by FileName was unused
    directly or indirectly in a given module outside of its group.
    It was not, however, directly included by the module and so may
    not easily be excluded without disturbing the header including
    it. Since this header may be included in other places caution is
    advised. This message is a weaker version of 766. See the
    discussion in §11.8.1 "Unused Headers". See also 964.
    But despite having set -wlib(0) and +libclass(angle,foreign,ansi) set on options.lnt, those two notes are still reported for library headers.

    I can't do -e964 and -e966 because these notes are useful for non library headers.

    I can't do -elib(964,966) because the notes report to the .cpp file being checked, not the library headers themselves. As such, it doesn't work.

    Is there any way I can avoid these notes for library headers?
    The programmer’s wife tells him: “Run to the store and pick up a loaf of bread. If they have eggs, get a dozen.”
    The programmer comes home with 12 loaves of bread.


    Originally Posted by brewbuck:
    Reimplementing a large system in another language to get a 25% performance boost is nonsense. It would be cheaper to just get a computer which is 25% faster.

  2. #2
    (?<!re)tired Mario F.'s Avatar
    Join Date
    May 2006
    Location
    Portugal
    Posts
    7,438
    Next time I'll give it an extra effort not to ask, knowing that probably if I just keep looking for the answer, I'll find it.

    If I had actually inhibited those notes with -e964 and -e966, I would have found that I still get reported for unused header files with Info 766.

    Sorry to bother you, good people. Solved.
    The programmer’s wife tells him: “Run to the store and pick up a loaf of bread. If they have eggs, get a dozen.”
    The programmer comes home with 12 loaves of bread.


    Originally Posted by brewbuck:
    Reimplementing a large system in another language to get a 25% performance boost is nonsense. It would be cheaper to just get a computer which is 25% faster.

Popular pages Recent additions subscribe to a feed

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21