blob: e8e3cbb6843f660bf66440f1ae2ee9885a5e61b7 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
import java.io.IOException;
public aspect Pr103097 {
declare soft: IOException:
within(Pr103097) &&
!withincode(* *(..)) &&
!call(* *(..));
before() : execution(* main(..)) {
try {
doThrow();
} catch (IOException e) {
throw new RuntimeException("IOException not softened as expected");
} catch(org.aspectj.lang.SoftException ex) {}
}
public static void doThrow() throws IOException {
throw new IOException("test");
}
public static void main(String args[]) {
}
}
|