by auno · 3y ago · 0 comments
If you bend over far enough backwards, and squint a bit, you can kind of do that...
interface Runner<E extends Throwable> {
public void run() throws E;
}
class Test {
public static <E extends Throwable, T extends Runner<E>> void test(T runner) throws E {
runner.run();
}
}
It compiles. I haven't tried running it though.No comments yet.