aboutsummaryrefslogtreecommitdiffstats
path: root/tests/java5/decps/Basic2b.java
diff options
context:
space:
mode:
Diffstat (limited to 'tests/java5/decps/Basic2b.java')
-rw-r--r--tests/java5/decps/Basic2b.java30
1 files changed, 30 insertions, 0 deletions
diff --git a/tests/java5/decps/Basic2b.java b/tests/java5/decps/Basic2b.java
new file mode 100644
index 000000000..babd57f52
--- /dev/null
+++ b/tests/java5/decps/Basic2b.java
@@ -0,0 +1,30 @@
+import org.aspectj.lang.annotation.*;
+
+public class Basic2b {
+ public static void main(String []argv) {
+ Basic2b b = new Basic2b();
+ if (!(b instanceof X.I)) throw new RuntimeException("Basic2b should implement I");
+ }
+}
+
+
+
+@Aspect class X {
+
+ interface I {
+ }
+
+ class IIimpl implements I {
+ public void m2() { }
+ }
+
+
+ @DeclareParents("Basic2b",defaultimpl="IImpl")
+ private I simplefield;;
+
+
+ @Before("execution(* *(..))")
+ public void advice1() {}
+
+}
+