summaryrefslogtreecommitdiffstats
path: root/tests/bugs1612/pr352363/Code.java
blob: 2c2713390a984228e1f48ec77fc0d26e2b1f9574 (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
25
import java.lang.annotation.*;

public class Code {

  @Anno
  int i=0;

  @Anno(name="foobar")
  int j=0;

  public void m() {
    i = i+1;
    j = j+1;
  }
}

@Retention(RetentionPolicy.RUNTIME)
@interface Anno {
  String name() default "";
}

aspect X {
  declare warning: get(@Anno(name="") * *) : "name is empty1";
  declare warning: get(@Anno(name="foobar") * *) : "name is empty2";
}