Files
openide/java/java-impl/resources/inspectionDescriptions/UnnecessaryBlockStatement.html
Leonid Shalupov 40795fe787 IJI-2422: community/java: move resources under resources root
GitOrigin-RevId: 8b2b63fc6db476ca0c2cfe5cadd84db6c4236d0f
2025-02-05 04:43:28 +00:00

24 lines
666 B
HTML

<html>
<body>
Reports code blocks that are redundant to the semantics of the program and can
be replaced with their contents.
<p>The code blocks that are the bodies of <code>if</code>, <code>do</code>,
<code>while</code>, or <code>for</code> statements will not be reported by this
inspection.</p>
<p>Example:</p>
<pre><code>
void foo() {
{ // unnecessary
int result = call();
analyze(result);
} // unnecessary
}
</code></pre>
<!-- tooltip end -->
<p>Configure the inspection:</p>
<p>
Use the <b>Ignore branches of 'switch' statements</b> option to ignore the code blocks that are used as branches of switch statements.
<p>
</body>
</html>