mirror of
https://gitflic.ru/project/openide/openide.git
synced 2025-12-26 12:20:55 +07:00
13 lines
359 B
Java
13 lines
359 B
Java
class ErrorTest {
|
|
public static <E1 extends Throwable> void rethrow(Thrower<? extends E1> thrower) {
|
|
try {
|
|
thrower.doThrow();
|
|
}
|
|
catch (Throwable e) {
|
|
<error descr="Unhandled exception: E1">throw e;</error>
|
|
}
|
|
}
|
|
interface Thrower<E extends Throwable> {
|
|
void doThrow() throws E;
|
|
}
|
|
} |