Get the error from eisop/jdk#122
Take this code:
import org.checkerframework.checker.nullness.qual.EnsuresNonNullIf;
public class Demo{
@EnsuresNonNullIf(expression = { "#1" }, result = true)
public native void test(Object obj);
}
Error from Nullness Checker:
Demo.java:6: error: [flowexpr.parameter.not.final] parameter obj in 'obj' is not effectively final (i.e., it gets re-assigned)
public native void test(Object obj);
^
1 error
We should treat the parameters of native method as effective final, like abstract method.
Get the error from eisop/jdk#122
Take this code:
Error from Nullness Checker:
We should treat the parameters of native method as effective final, like
abstractmethod.