Menu

how can i use the cppcheck arguments?

2015-09-07
2015-09-08
  • Joaquim Miguel

    Joaquim Miguel - 2015-09-07

    i'm using the Code Blocks. the Code Blocks have a cppcheck plugin. but i don't know use the cppcheck exe arguments :(
    can anyone help me just for read\test my header file and not all include files using the arguments?

     
  • Daniel Marjamäki

    I'd write a source file that just includes the header:

    #include "foo.h"
    

    Then run cppcheck on the source file

    cppcheck --enable=warning dummy.cpp
    

    You could run cppcheck on foo.h directly:

    cppcheck --enable=warning foo.h
    

    but when running cppcheck directly on header files the analysis is not accurate.

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.