mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-18 09:34:34 +07:00
register Java fields referenced from injected fragments as read/written
This commit is contained in:
@@ -50,4 +50,31 @@ class PrivateClassTest {
|
||||
f(b, param);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
class IncrementedButNeverAccessed {
|
||||
private int <warning descr="Private field 'ffff' is assigned but never accessed">ffff</warning>;
|
||||
|
||||
void foo(int p) {
|
||||
if (p == 0) return;
|
||||
ffff++;
|
||||
}
|
||||
}
|
||||
class IncrementedAndPassed {
|
||||
private int ffff;
|
||||
|
||||
void foo(int p) {
|
||||
if (p == 0) return;
|
||||
foo(ffff++);
|
||||
}
|
||||
}
|
||||
class IncrementedAndRead{
|
||||
private int ffff;
|
||||
|
||||
void foo(int p) {
|
||||
if (p == 0) return;
|
||||
p = ffff++;
|
||||
if (p == 0) foo(p);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user