title: What open source C++ static analysis tools are available?
body: <p>Java has some very good open source static analysis tools such as <a href="http://findbugs.sf.net/" rel="nofollow noreferrer">FindBugs</a>, <a href="http://checkstyle.sf.net/" rel="nofollow noreferrer">Checkstyle</a> and <a href="http://pmd.sf.net/" rel="nofollow noreferrer">PMD</a>.  Those tools are easy to use, very helpful, runs on multiple operating systems and <em>free</em>.</p>
  <p>Commercial C++ static analysis products are available. Although having such products are great, the cost is just way too much for students and it is usually rather hard to get trial version.</p>
  <p>The alternative is to find open source C++ static analysis tools that will run on multiple platforms (Windows and Unix). By using an open source tool, it could be modified to fit certain needs.  Finding the tools has not been easy task.</p>
  <p>Below is a short list of C++ static analysis tools that were found or suggested by others.</p>
  <ul>
  <li>C++ Check <a href="http://sf.net/projects/cppcheck/" rel="nofollow noreferrer">http://sf.net/projects/cppcheck/</a></li>
  <li>Oink <a href="http://danielwilkerson.com/oink/index.html" rel="nofollow noreferrer">http://danielwilkerson.com/oink/index.html</a></li>
  <li>C and C++ Code Counter <a href="http://sourceforge.net/projects/cccc/" rel="nofollow noreferrer">http://sourceforge.net/projects/cccc/</a></li>
  <li>Splint (from answers)</li>
  <li>Mozilla's Pork (from answers) (This is now part of Oink)</li>
  <li>Mozilla's Dehydra (from answers)</li>
  <li>Use option <code>-Weffc++</code> for GNU g++ (from answers)</li>
  </ul>
  <p>What are some <strong>other</strong> portable open source C++ static analysis tools that anyone knows of and can be recommended?</p>
  <p>Some related links.</p>
  <ul>
  <li><a href="http://en.wikipedia.org/wiki/List_of_tools_for_static_code_analysis" rel="nofollow noreferrer">http://en.wikipedia.org/wiki/List_of_tools_for_static_code_analysis</a></li>
  <li><a href="http://www.chris-lott.org/resources/cmetrics/" rel="nofollow noreferrer">http://www.chris-lott.org/resources/cmetrics/</a></li>
  <li><a href="https://stackoverflow.com/questions/93260/a-free-tool-to-check-cc-source-code-against-a-set-of-coding-standards">A free tool to check C/C++ source code against a set of coding standards?</a></li>
  <li><a href="http://spinroot.com/static/" rel="nofollow noreferrer">http://spinroot.com/static/</a></li>
  <li><a href="https://stackoverflow.com/questions/2873/choosing-a-static-code-analysis-tool">Choosing a static code analysis tool</a></li>
  </ul>