blob: 8eb54831684307d0281ec35e198863fed180877b [file] [log] [blame]
import java.io.IOException;
class Test {
interface F<T extends Throwable> {
void _() throws T;
}
void m1() { }
void m2() throws NullPointerException{ }
void m3() throws IOException { }
<K extends Throwable> void foo(F<K> f) throws K { }
{
foo(()->{});
foo(()->{throw new NullPointerException();});
foo(this::m1);
foo(this::m2);
<error descr="Unhandled exception: java.io.IOException">foo(this::m3);</error>
}
}