aboutsummaryrefslogtreecommitdiffstats
path: root/tests/bugs163
diff options
context:
space:
mode:
authoraclement <aclement>2008-12-09 19:21:17 +0000
committeraclement <aclement>2008-12-09 19:21:17 +0000
commitf1a83b5f2ba583e3c18542f962b569847a863844 (patch)
treee2cf08311fc4799359053a8c2af4026bfb9b5de3 /tests/bugs163
parent364e330f369eb4002c1596b6b425053bc92d3310 (diff)
downloadaspectj-f1a83b5f2ba583e3c18542f962b569847a863844.tar.gz
aspectj-f1a83b5f2ba583e3c18542f962b569847a863844.zip
251326: testcase
Diffstat (limited to 'tests/bugs163')
-rw-r--r--tests/bugs163/pr251326/pkgA/Listener.java7
-rw-r--r--tests/bugs163/pr251326/pkgA/Target.java19
-rw-r--r--tests/bugs163/pr251326/pkgB/InferListener.aj16
3 files changed, 42 insertions, 0 deletions
diff --git a/tests/bugs163/pr251326/pkgA/Listener.java b/tests/bugs163/pr251326/pkgA/Listener.java
new file mode 100644
index 000000000..d3a6f68ea
--- /dev/null
+++ b/tests/bugs163/pr251326/pkgA/Listener.java
@@ -0,0 +1,7 @@
+package pkgA;
+
+public interface Listener {
+
+ public void happened(String event);
+
+}
diff --git a/tests/bugs163/pr251326/pkgA/Target.java b/tests/bugs163/pr251326/pkgA/Target.java
new file mode 100644
index 000000000..00e1a5f5a
--- /dev/null
+++ b/tests/bugs163/pr251326/pkgA/Target.java
@@ -0,0 +1,19 @@
+package pkgA;
+
+public class Target {
+
+ public Listener listenA() {
+ return new Listener() {
+ public void happened(String event) {
+ System.out.println(event);
+ }
+ };
+ }
+
+ public static void main(String[] args) {
+ Target t = new Target();
+ t.listenA().happened("Simple A");
+ t.listenB().happened("Inferred B");
+ }
+
+}
diff --git a/tests/bugs163/pr251326/pkgB/InferListener.aj b/tests/bugs163/pr251326/pkgB/InferListener.aj
new file mode 100644
index 000000000..7dfa14132
--- /dev/null
+++ b/tests/bugs163/pr251326/pkgB/InferListener.aj
@@ -0,0 +1,16 @@
+package pkgB;
+
+import pkgA.Listener;
+import pkgA.Target;
+
+public aspect InferListener {
+
+ public Listener Target.listenB() {
+ return new Listener() {
+ public void happened(String event) {
+ System.out.println(event);
+ }
+ };
+ }
+
+}