aboutsummaryrefslogtreecommitdiffstats
path: root/tests/features160/parameterValueMatching/Broken1.java
blob: ab0877c741fd493954255a8828f35f8a5467c9b9 (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
26
27
28
29
enum Color { RED, GREEN, AMBER }

@interface TrafficLight {
	Color value() default Color.RED;
}

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

class Marked {

  public void a() {}

  @TrafficLight
  public void b() {}

  @TrafficLight(Color.RED)
  public void c() {}

  @TrafficLight(Color.GREEN)
  public void d() {}
}

aspect X {	
  pointcut p1(): execution(@TrafficLight(a) * *(..)); // value of just 'a' doesn't mean anything - only enums supported right now, let's say 'invalid annotation value'
}