interface I {
}
- class IImpl implements I {
+ static class IImpl implements I {
public void m2() { }
}
public void m4();
}
- class IImpl implements I {
+ static class IImpl implements I {
public void m2() { }
public void m3() { }
public void m4() { }
--- /dev/null
+import org.aspectj.lang.annotation.*;
+
+public class Basic3c {
+ public static void main(String []argv) {
+ Basic3c b = new Basic3c();
+ if (!(b instanceof X.I)) throw new RuntimeException("Basic3c should implement I");
+ ((X.I)b).m2();
+ ((X.I)b).m3();
+ ((X.I)b).m2();
+ ((X.I)b).m4();
+ }
+}
+
+
+
+@Aspect class X {
+
+ interface I {
+ public void m2();
+ public void m3();
+ public void m4();
+ }
+
+ class IImpl implements I {
+ public void m2() { }
+ public void m3() { }
+ public void m4() { }
+ }
+
+
+ @DeclareParents(value="Basic3c",defaultImpl=IImpl.class)
+ private I simplefield;
+
+
+ @Before("call(* *(..))")
+ public void advice1() {}
+
+}
+
public void testDecps2() { runTest("decps - 2");}
public void testDecps2b() { runTest("decps - 2b");}
public void testDecps3() { runTest("decps - 3");}
- // public void testDecps3b() { runTest("decps - 3b");}
+ public void testDecps3b() { runTest("decps - 3b");}
+ public void testDecps3c() { runTest("decps - 3c");}
public void testVarargsNPE_pr120826() { runTest("varargs NPE");}
public void testNamedPointcutPertarget_pr120521() { runTest("named pointcut not resolved in pertarget pointcut");}
<run class="Basic3b"/>
</ajc-test>
+ <ajc-test dir="java5/decps" title="decps - 3c">
+ <compile files="Basic3c.java" options="-1.5">
+ </compile>
+ <run class="Basic3c"/>
+ </ajc-test>
+
<ajc-test dir="bugs150/pr119570" pr="119570" title="spurious override method warning">