mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-01-08 23:39:39 +07:00
new inference: prohibit substitution during checked exception constraint processing
This commit is contained in:
@@ -0,0 +1,29 @@
|
||||
import java.io.IOException;
|
||||
import java.util.List;
|
||||
|
||||
class Test {
|
||||
|
||||
interface A<T> {
|
||||
T m(T t);
|
||||
}
|
||||
|
||||
interface B<K> {
|
||||
List<K> l(K k) throws IOException;
|
||||
}
|
||||
|
||||
<F> F foo(A<F> a) {
|
||||
return null;
|
||||
}
|
||||
|
||||
<R> R bar(B<R> b) {
|
||||
return null;
|
||||
}
|
||||
|
||||
<Z> List<Z> baz(Z l) throws IOException{
|
||||
return null;
|
||||
}
|
||||
|
||||
{
|
||||
Integer i = foo(a -> bar(b -> baz(b)));
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user