### Eclipse Workspace Patch 1.0 #P org.eclipse.jdt.core Index: compiler/org/eclipse/jdt/internal/compiler/lookup/Scope.java =================================================================== RCS file: /cvsroot/eclipse/org.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/lookup/Scope.java,v retrieving revision 1.321 diff -u -r1.321 Scope.java --- compiler/org/eclipse/jdt/internal/compiler/lookup/Scope.java 7 Jan 2008 14:16:19 -0000 1.321 +++ compiler/org/eclipse/jdt/internal/compiler/lookup/Scope.java 21 Jan 2008 13:32:39 -0000 @@ -2596,11 +2596,6 @@ TypeBinding oneParam = oneParams[i]; TypeBinding twoParam = twoParams[i]; if (oneParam == twoParam) { - if (oneParam.leafComponentType().isRawType()) { - // A#RAW is not more specific than a rawified A - if (oneParam == one.original().parameters[i] && oneParam != two.original().parameters[i]) - return false; - } continue; } if (oneParam.isCompatibleWith(twoParam)) { #P org.eclipse.jdt.core.tests.compiler Index: src/org/eclipse/jdt/core/tests/compiler/regression/GenericTypeTest.java =================================================================== RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/regression/GenericTypeTest.java,v retrieving revision 1.680 diff -u -r1.680 GenericTypeTest.java --- src/org/eclipse/jdt/core/tests/compiler/regression/GenericTypeTest.java 17 Jan 2008 13:00:31 -0000 1.680 +++ src/org/eclipse/jdt/core/tests/compiler/regression/GenericTypeTest.java 21 Jan 2008 13:32:48 -0000 @@ -41119,4 +41119,47 @@ false, null); } +//https://bugs.eclipse.org/bugs/show_bug.cgi?id=215843 - variation +public void test1232() { + this.runConformTest( + new String[] { + "X.java", + "public class X {\n" + + " public static void testCovariant(SubInterface sub1, SubInterface sub2) {\n" + + " SubInterface sub3 = sub1.and(sub2);\n" + + " }\n" + + " public interface SuperInterface {\n" + + " public Number getNumber();\n" + + " public SuperInterface and(SuperInterface a);\n" + + " }\n" + + " public interface SubInterface extends SuperInterface {\n" + + " public Integer getNumber();\n" + + " public SubInterface and(SuperInterface s);\n" + + " }\n" + + "}\n", + }, + ""); + +} +//https://bugs.eclipse.org/bugs/show_bug.cgi?id=215843 - variation +public void test1233() { + this.runConformTest( + new String[] { + "X.java", + "public class X {\n" + + " public static void testCovariant(SubInterface sub1, SubInterface sub2) {\n" + + " SubInterface sub3 = sub1.and(sub2);\n" + + " }\n" + + " public interface SuperInterface {\n" + + " public Number getNumber();\n" + + " public SuperInterface and(SuperInterface a);\n" + + " }\n" + + " public interface SubInterface extends SuperInterface {\n" + + " public Integer getNumber();\n" + + " public SubInterface and(SuperInterface s);\n" + + " }\n" + + "}\n", + }, + ""); +} }