summaryrefslogtreecommitdiffstats
path: root/tests/bugs153
diff options
context:
space:
mode:
Diffstat (limited to 'tests/bugs153')
-rw-r--r--tests/bugs153/pr158126/A.java17
-rw-r--r--tests/bugs153/pr158126/B.java12
-rw-r--r--tests/bugs153/pr158126/MyAnnotation.java7
-rw-r--r--tests/bugs153/pr158126/MyAspect.java7
4 files changed, 43 insertions, 0 deletions
diff --git a/tests/bugs153/pr158126/A.java b/tests/bugs153/pr158126/A.java
new file mode 100644
index 000000000..d92c77fcb
--- /dev/null
+++ b/tests/bugs153/pr158126/A.java
@@ -0,0 +1,17 @@
+public class A {
+
+ @MyAnnotation
+ public A() {
+ new B();
+ }
+
+ @MyAnnotation
+ public A(int i) {
+ new B(i);
+ }
+
+ public static void main(String[] args) {
+ new A();
+ new A(1);
+ }
+}
diff --git a/tests/bugs153/pr158126/B.java b/tests/bugs153/pr158126/B.java
new file mode 100644
index 000000000..bdbfa788d
--- /dev/null
+++ b/tests/bugs153/pr158126/B.java
@@ -0,0 +1,12 @@
+public class B {
+
+ @MyAnnotation
+ public B() {
+
+ }
+
+ @MyAnnotation
+ public B(int i) {
+
+ }
+}
diff --git a/tests/bugs153/pr158126/MyAnnotation.java b/tests/bugs153/pr158126/MyAnnotation.java
new file mode 100644
index 000000000..33d13ead8
--- /dev/null
+++ b/tests/bugs153/pr158126/MyAnnotation.java
@@ -0,0 +1,7 @@
+import java.lang.annotation.*;
+
+@Target(ElementType.CONSTRUCTOR)
+@Retention(RetentionPolicy.RUNTIME)
+public @interface MyAnnotation {
+
+}
diff --git a/tests/bugs153/pr158126/MyAspect.java b/tests/bugs153/pr158126/MyAspect.java
new file mode 100644
index 000000000..0ab4a323e
--- /dev/null
+++ b/tests/bugs153/pr158126/MyAspect.java
@@ -0,0 +1,7 @@
+public aspect MyAspect {
+
+ before() :
+ call(@MyAnnotation *.new(..)) {
+ System.out.println(thisJoinPoint);
+ }
+}