Files
Tagir Valeevandintellij-monorepo-bot ce4fd32826 Fix toString for primitive array
GitOrigin-RevId: 874ce61f92a2f361f0a419f6b60c93fdc11cf21f
2020-02-10 11:03:00 +00:00

14 lines
472 B
Java

/*
Value is always true (obj instanceof Cloneable; line#12)
An object type is exactly int[] which is a subtype of Cloneable (obj; line#12)
Type of 'obj' is known from line #11 (c == obj.getClass(); line#11)
*/
import java.util.stream.Stream;
class A
public void foo(Object obj) {
if (Stream.of(CharSequence.class, Number.class, int[].class)
.noneMatch(c -> c == obj.getClass())) return;
if (<selection>obj instanceof Cloneable</selection>) {}
}
}