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

23 lines
772 B
HTML

<html>
<body>
Reports instance variables that are read before initialization.
<p>The inspection ignores equality checks with <code>null</code>.</p>
<p><b>Example:</b></p>
<pre><code>
class Foo {
int bar;
Foo() {
System.out.println(bar);
}
}
</code></pre>
<p>Note that this inspection uses a very conservative dataflow algorithm and may incorrectly report instance variables as uninitialized. Variables
reported as initialized will always be initialized.
<!-- tooltip end -->
<p>Use the <b>Ignore if annotated by</b> option to specify special annotations. The inspection will ignore fields
annotated with one of these annotations.</p>
<p>Use the <b>Ignore primitive fields</b> option to ignore uninitialized primitive fields.</p>
</body>
</html>