mirror of
https://github.com/github/codeql.git
synced 2026-07-21 19:22:02 +02:00
31 lines
742 B
XML
31 lines
742 B
XML
<!DOCTYPE qhelp PUBLIC
|
|
"-//Semmle//qhelp//EN"
|
|
"qhelp.dtd">
|
|
<qhelp>
|
|
|
|
|
|
<overview>
|
|
<p>This rule finds functions that are non-public, non-virtual and are never called. Dead functions are often deprecated pieces of code, and should be removed
|
|
as they may increase object code size, decrease code comprehensibility, and create the possibility of misuse.</p>
|
|
|
|
<p>
|
|
<code>public</code> and <code>protected</code> functions are not considered by the check, as they could be part of the program's
|
|
API and could be used by external programs.
|
|
</p>
|
|
|
|
<include src="callGraphWarning.qhelp" />
|
|
|
|
</overview>
|
|
<recommendation>
|
|
<p>Consider removing the function.</p>
|
|
|
|
</recommendation>
|
|
<example><sample src="DeadCodeFunction.cpp" />
|
|
|
|
|
|
|
|
|
|
|
|
</example>
|
|
</qhelp>
|