aboutsummaryrefslogtreecommitdiffstats
path: root/tests/bugs195
diff options
context:
space:
mode:
Diffstat (limited to 'tests/bugs195')
-rw-r--r--tests/bugs195/switch/Azpect.java5
-rw-r--r--tests/bugs195/switch/HelloWorldEnumSwitch.java22
2 files changed, 27 insertions, 0 deletions
diff --git a/tests/bugs195/switch/Azpect.java b/tests/bugs195/switch/Azpect.java
new file mode 100644
index 000000000..4e5c62e4a
--- /dev/null
+++ b/tests/bugs195/switch/Azpect.java
@@ -0,0 +1,5 @@
+aspect Azpect {
+ before(): within(HelloWorldEnumSwitch) {
+ System.out.println(">"+thisJoinPointStaticPart.getSourceLocation().getLine());
+ }
+}
diff --git a/tests/bugs195/switch/HelloWorldEnumSwitch.java b/tests/bugs195/switch/HelloWorldEnumSwitch.java
new file mode 100644
index 000000000..59c2f58c1
--- /dev/null
+++ b/tests/bugs195/switch/HelloWorldEnumSwitch.java
@@ -0,0 +1,22 @@
+public class HelloWorldEnumSwitch {
+
+ public static void main(String[] args) {
+ switch(TestEnum.A) {
+ case A:
+ System.out.println("A");
+ break;
+ case B:
+ System.out.println("B");
+ }
+
+ }
+
+ public static enum TestEnum {
+ A,
+ B;
+
+ private TestEnum() {
+ }
+ }
+}
+