blob: 99d80812f1190f5ca82a0de6d07035874fd8824e [file]
/*
Call always fails (foo(s, "checked"); line#12)
According to inferred contract, method 'foo' throws exception when obj == null (foo; line#12)
Condition 's == null' was checked before (s == null; line#11)
*/
import java.util.Objects;
class Test {
void test(String s) {
if (s == null) {
<selection>foo(s, "checked")</selection>;
}
}
static void foo(Object obj, String message) {
if(obj == null) {
throw new RuntimeException(message);
}
}
}