Summary: | [1.5][compiler] Incorrect ambiguous method error involving abstract classes and enums | ||
---|---|---|---|
Product: | [Eclipse Project] JDT | Reporter: | Maxime Daniel <maxime_daniel> |
Component: | Core | Assignee: | Kent Johnson <kent_johnson> |
Status: | VERIFIED FIXED | QA Contact: | |
Severity: | normal | ||
Priority: | P3 | CC: | jerome_lanneluc, philippe_mulet |
Version: | 3.3 | ||
Target Milestone: | 3.3.1 | ||
Hardware: | PC | ||
OS: | Windows XP | ||
Whiteboard: |
Description
Maxime Daniel
2007-06-19 03:04:47 EDT
This is a strange case. We do not report a problem with this : enum E implements I { F; } interface I {} interface Spec { <T extends Enum<T> & I> void method(T t); } //abstract class X implements Spec { class X implements Spec { public <T extends Enum<T> & I> void method(T t) {} void test() { method(E.F); } } But we do report an incorrect ambiguous error when X is abstract. Added AmbiguousMethodTest 62 Released into HEAD for 3.4 M2 Released for 3.3.1 +1 for 3.3.1 The regression test leverages the scenario of comment 1, not the original test case provided. The former might well be a true proxy for the latter (at least the same fix addresses both situations), but since this is not that obvious when reading both, you may consider adding a regression test for the original test case. Anyway, Verified for 3.3.1 using build M20070831-2000. Verified for 3.4 using I20070917-0010 |