diff options
author | Andy Clement <aclement@pivotal.io> | 2016-05-12 15:27:22 -0700 |
---|---|---|
committer | Andy Clement <aclement@pivotal.io> | 2016-05-12 15:27:22 -0700 |
commit | d8ccdb732982e855a9d1a17c844a9d85a3a82866 (patch) | |
tree | 496d3a933eb08e865a5fb49b7cf96735df4ed08c /tests/bugs1810/493554 | |
parent | 318abf5c887102af8e51337a75fa910449df86b9 (diff) | |
download | aspectj-d8ccdb732982e855a9d1a17c844a9d85a3a82866.tar.gz aspectj-d8ccdb732982e855a9d1a17c844a9d85a3a82866.zip |
Fix 493554 - Missing InnerClasses attribute for nested interfaces created by AspectJ
Diffstat (limited to 'tests/bugs1810/493554')
-rw-r--r-- | tests/bugs1810/493554/Cmd.java | 10 | ||||
-rw-r--r-- | tests/bugs1810/493554/Cmd.kt | 9 | ||||
-rw-r--r-- | tests/bugs1810/493554/Code.java | 5 | ||||
-rw-r--r-- | tests/bugs1810/493554/Dep.java | 14 | ||||
-rw-r--r-- | tests/bugs1810/493554/FooAspect.aj | 17 | ||||
-rw-r--r-- | tests/bugs1810/493554/FooAspect.java | 25 |
6 files changed, 80 insertions, 0 deletions
diff --git a/tests/bugs1810/493554/Cmd.java b/tests/bugs1810/493554/Cmd.java new file mode 100644 index 000000000..8954d08af --- /dev/null +++ b/tests/bugs1810/493554/Cmd.java @@ -0,0 +1,10 @@ +package example.kusedep; + +import example.dep.Dep; + +public class Cmd { + public static void main(String[] args) { + Dep dep = new Dep(); + System.out.println(dep); + } +} diff --git a/tests/bugs1810/493554/Cmd.kt b/tests/bugs1810/493554/Cmd.kt new file mode 100644 index 000000000..a9a0238eb --- /dev/null +++ b/tests/bugs1810/493554/Cmd.kt @@ -0,0 +1,9 @@ +package example.kusedep; + +import example.dep.Dep; + +fun main(args: Array<String>) { + val dep = Dep() + println(dep) + System.exit(0) +} diff --git a/tests/bugs1810/493554/Code.java b/tests/bugs1810/493554/Code.java new file mode 100644 index 000000000..16a6a642b --- /dev/null +++ b/tests/bugs1810/493554/Code.java @@ -0,0 +1,5 @@ +public class Code { + public static void main(String []argv) { + new Runnable() { public void run() {}}; + } +} diff --git a/tests/bugs1810/493554/Dep.java b/tests/bugs1810/493554/Dep.java new file mode 100644 index 000000000..8ed5c1500 --- /dev/null +++ b/tests/bugs1810/493554/Dep.java @@ -0,0 +1,14 @@ +package example.dep;
+
+public class Dep {
+ private int a, b, c;
+
+ public Dep() {
+ a = 5;
+ }
+
+ public String toString() {
+
+ return "Dep";
+ }
+}
diff --git a/tests/bugs1810/493554/FooAspect.aj b/tests/bugs1810/493554/FooAspect.aj new file mode 100644 index 000000000..4ad4c22cc --- /dev/null +++ b/tests/bugs1810/493554/FooAspect.aj @@ -0,0 +1,17 @@ +package example.aspect; + +import example.dep.Dep; + +public aspect FooAspect pertarget(setFieldValue(Dep)) { + + // interface ajcMightHaveAspect { } + + pointcut setFieldValue(Dep dep) : + set(private * Dep.*) && target(dep); + + void around(Dep dep) : setFieldValue(dep) { +System.out.println("advised"); + proceed(dep); + } + +} diff --git a/tests/bugs1810/493554/FooAspect.java b/tests/bugs1810/493554/FooAspect.java new file mode 100644 index 000000000..87406db94 --- /dev/null +++ b/tests/bugs1810/493554/FooAspect.java @@ -0,0 +1,25 @@ + +package example.aspect; + +import org.aspectj.lang.*; +import org.aspectj.lang.annotation.*; + +import example.dep.Dep; + +@Aspect("pertarget(setFieldValue(example.dep.Dep))") +public class FooAspect { + + // interface ajcMightHaveAspect { } + + @Pointcut("set(private * example.dep.Dep.*) && target(dep)") + public void setFieldValue(Dep dep) {} + //pointcut setFieldValue(Dep dep) : set(private * Dep.*) && target(dep); + + @Around("setFieldValue(dep)") + public void foo(Dep dep, ProceedingJoinPoint pjp) { + //void around(Dep dep) : setFieldValue(dep) { +System.out.println("advised"); + pjp.proceed(new Object[]{dep}); + } + +} |