aboutsummaryrefslogtreecommitdiffstats
path: root/tests/features152/synchronization/transformed/Eight.java
blob: 79af0a6251012c4beba417980b8a2a7853488d1d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
import java.io.File;
import java.io.FileInputStream;
import java.io.IOException;

// matching unlock in a transformed non-static method...

public aspect Eight {
  public static void main(String[] args) {
    new C().b();
  }

  before(): !within(Eight) && unlock() { 
    System.err.println("Unlocking occurring at "+thisJoinPoint);
    System.err.println(thisJoinPoint.getSourceLocation().getFileName());
  }
}
  
class C {
  public synchronized void b() {
    System.err.println("hello");
  }
}