#author("2022-02-03T12:17:12+00:00","","")
#author("2022-02-03T12:22:52+00:00","","")
#topicpath

//////////////////////////////////////////////////////////////////////////////
* 目次 [#jb02534e]
#contents();

//////////////////////////////////////////////////////////////////////////////
* cppcheck [#h7e27ef6]
- C/C++ 用静的コード解析ツール

//////////////////////////////////////////////////////////////////////////////
* 使い方 [#bae65ed4]
//============================================================================
** コマンド書式 [#o1db9256]
 $ cppcheck --enable=all <input>
 $ cppcheck <option[s]> <input>
- <input> には、ソースファイル、またはソースファイルのあるディレクトリを指定する。

//============================================================================
** option [#y7f7d3e3]
|~option    |~description |~remark |
|--std=<id> |[[言語標準>#language-std]]を指定する。 | |

- &aname(option-enableenable){--enable=<option>};
|~option |~description |~remark |
|all     |Enable all checks  | |
|warning |Enable warning messages | |
|style   |Enable all coding style checks. | |
|performance |Enable performance messages | |
|portability    |Enable portability messages | |
|information    |Enable information messages | |
|unusedFunction |Check for unused functions. It is recommend to only enable this when the whole program is scanned | |
|missingInclude |Warn if there are missing includes. For detailed information use --check-config | |



- &aname(language-std){言語標準の指定};
|~id   |~description                           |~remark |
|posix |POSIX compatible code                  | |
|c89   |C code is C89 compatible               | |
|c99   |C code is C99 compatible               | |
|c11   |C code is C11 compatible (default)     | |
|c++03 |C++ code is C++03 compatible           | |
|c++11 |C++ code is C++11 compatible (default) | |



//////////////////////////////////////////////////////////////////////////////
* 参考リンク [#zd39f3ed]
- [[Cppcheck - A tool for static C/C++ code analysis>https://cppcheck.sourceforge.io/]] --- 開発元

トップ   編集 差分 履歴 添付 複製 名前変更 リロード   新規 一覧 検索 最終更新   ヘルプ   最終更新のRSS