aboutsummaryrefslogtreecommitdiffstats
path: root/tests/bugs169/pr298388
diff options
context:
space:
mode:
authoraclement <aclement>2010-01-25 22:47:06 +0000
committeraclement <aclement>2010-01-25 22:47:06 +0000
commitd36b87d2f0b22991ffc8d111367fdb7c97943477 (patch)
tree85355c0aedc8e8b4ca4510f5d948e9bf94cc842f /tests/bugs169/pr298388
parent046261e20078530352a063c6c1eef9f44bb98f23 (diff)
downloadaspectj-d36b87d2f0b22991ffc8d111367fdb7c97943477.tar.gz
aspectj-d36b87d2f0b22991ffc8d111367fdb7c97943477.zip
292584, 295491, 298388: testcode
Diffstat (limited to 'tests/bugs169/pr298388')
-rw-r--r--tests/bugs169/pr298388/PR298388.java42
1 files changed, 42 insertions, 0 deletions
diff --git a/tests/bugs169/pr298388/PR298388.java b/tests/bugs169/pr298388/PR298388.java
new file mode 100644
index 000000000..dae3c1013
--- /dev/null
+++ b/tests/bugs169/pr298388/PR298388.java
@@ -0,0 +1,42 @@
+import org.aspectj.lang.annotation.Aspect;
+import org.aspectj.lang.annotation.DeclareMixin;
+
+@Aspect
+public class PR298388 {
+
+ @DeclareMixin("Thing2")
+ public static <T> Thing<T> createThingImplementation() {
+ return new ThingImpl<T>();
+ }
+
+ public static void main(String[] args) {
+ Thing<String> ts = (Thing<String>) new Thing2<String>();
+ ts.wibble();
+ ts.wibble("abc");
+ String s = ts.wibbleBack("wobble");
+ System.out.println("done");
+ }
+
+}
+
+class Thing2<X> {
+}
+
+interface Thing<X> {
+ void wibble();
+ void wibble(X x);
+ X wibbleBack(X x);
+}
+
+class ThingImpl<X> implements Thing<X> {
+ ThingImpl() {
+ }
+
+ public void wibble() {
+ }
+
+ public void wibble(X x) {}
+
+ public X wibbleBack(X x) { return x;}
+
+}