summaryrefslogtreecommitdiffstats
path: root/tests/bugs1612/pr239649/Five.java
blob: 80b8d21bc990b17fbd6c09889147ba92a390b5ef (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
public class Five {
  public static void main(String[] argv) {
    Five a = new Five();
    a.m("abc");
  }

  public void m(String s) {
    System.out.println("Method m() running");
  }
}

aspect X {
  boolean doit() {
    System.out.println("In instance check method doit()");
    return true;
  }

  before():execution(* m(..))  && if(thisAspectInstance.doit()){ 
    System.out.println("In advice() arg0="+thisJoinPoint.getArgs()[0]);
  }
}