blob: f7f37de8e5db8e3f087d584d8ccb1055fb579802 [file]
import org.jetbrains.annotations.Contract;
class Foo {
@Contract("_, null -> fail")
static <T, R extends T> boolean canCast(T inst, Class<R> toType) {
return toType.isInstance(inst);
}
}