You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

DeclareSoft2.java 340B

123456789101112131415161718192021
  1. import java.io.IOException;
  2. class DeclareSoft2 {
  3. public static void main(String[] x) {
  4. foo();
  5. }
  6. static void foo() throws IOException {
  7. throw new IOException();
  8. }
  9. }
  10. aspect A {
  11. void around(): call(void foo()) {
  12. try { proceed(); }
  13. catch (IOException e) {}
  14. }
  15. declare soft: IOException: call(void foo());
  16. }