mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-08 21:52:48 +07:00
Fixes IDEA-296799 'Constant conditions & exceptions' false positive when incrementing an array value GitOrigin-RevId: f018dc670016473a6cf80c06a91b80cb48afb4e0
17 lines
413 B
Java
17 lines
413 B
Java
public class ArrayWriteFlush {
|
|
public static void main(String[] args) {
|
|
int[] a = {0, 0};
|
|
int d = nextInt();
|
|
int x = a[d]++;
|
|
System.out.println(a[0] + a[1]);
|
|
System.out.println(x);
|
|
}
|
|
|
|
private static native int nextInt();
|
|
|
|
void invalidType() {
|
|
Object obj = 0;
|
|
<error descr="Operator '++' cannot be applied to 'java.lang.Object'">obj++</error>;
|
|
System.out.println(obj);
|
|
}
|
|
} |