aboutsummaryrefslogtreecommitdiffstats
path: root/tests/new/NewAnonymous.java
blob: 71f0edcb6818c2df6e963aad0617cbf7c8be96c2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
import org.aspectj.testing.Tester;

public class NewAnonymous {
    public static void main(String[] args) {
    }
}


class C {
    private String f = "fC";
    public void m(final String s) {
        new Runnable() {
                public void run() {
                    System.out.println(s+":"+f);
                }
            }.run();
    }
}

aspect A {
    before(): call(*.new()) {
        System.out.println("new Runnable");
    }
}