--- /dev/null
+import java.util.*;
+
+public class A<? extends M> {
+ public void foo(List<?> m) {}
+}
+class B extends A {
+ public void foo(List<? extends Object> m) {}
+}
--- /dev/null
+aspect MyAspect
+{
+ public interface MyInterface
+ {
+ public boolean instanceOf(Class<? extends Object> c);
+ //public boolean instanceOf(Class c);
+ }
+
+ declare parents: MyObject implements MyInterface;
+
+ public boolean MyInterface.instanceOf(Class<? extends Object> c)
+ //public boolean MyInterface.instanceOf(Class c)
+ {
+ return c.isInstance(this);
+ }
+}
+
+class MyObject
+{
+ // public boolean instanceOf(Class<? extends Object> c) {return true;}
+}
+
+public class Main
+{
+ public static void main(String[] args)
+ {
+ new MyObject().instanceOf(Object.class);
+ }
+}
public class Ajc169Tests extends org.aspectj.testing.XMLBasedAjcTestCase {
- //public void testStaticallyAnalyzableIf_292262_1() {
- // runTest("if with statically recognizable code");
- //}
+ // public void testStaticallyAnalyzableIf_292262_1() {
+ // runTest("if with statically recognizable code");
+ // }
public void testTypePatternCategories_44365_Class() {
runTest("type category type patterns - class");
runTest("type category type patterns - e2");
}
- /*
- * public void testAmbiguousMethod() { runTest("ambiguous method"); }
- */
+ // public void testAmbiguousMethod_298665() {
+ // runTest("ambiguous method");
+ // }
public void testChecker() {
runTest("inserts in messages");