| Summary: | Java generics code compiles with Galileo, fails with Helios (method argument erasure clash) | ||
|---|---|---|---|
| Product: | [Eclipse Project] JDT | Reporter: | Dominic Owen <d.owen> |
| Component: | Core | Assignee: | Srikanth Sankaran <srikanth_sankaran> |
| Status: | VERIFIED DUPLICATE | QA Contact: | |
| Severity: | major | ||
| Priority: | P3 | CC: | d.owen, Olivier_Thomann, prakash, rivashin, satyam.kandula, srikanth_sankaran |
| Version: | 3.6 | ||
| Target Milestone: | 3.7.1 | ||
| Hardware: | All | ||
| OS: | Linux | ||
| Whiteboard: | |||
Moving to JDT Core ... See that this fails to compile with JDK7 (b100) and the error message is the same as eclipse. *** This bug has been marked as a duplicate of bug 317719 *** Verified for 3.7M2 using I20100914-0100 junit has been added as a part of the fix for bug 317719 Verified for 3.7.1 RC2 using build M20110824-0800 Verified for 3.8M2 |
Build Identifier: Helios Release Build id: 20100617-1415 We have code that compiles and runs in all versions of eclipse (regardless of platform) except for Helios. The code below exhibits the bug: public class BugExample { protected static <T extends String> T same(Collection<? extends T> p_col) { return null; } protected static <T extends Number> T same(Collection<? extends T> p_col) { return null; } } The error message is: "Method same(Collection<? extends T>) has the same erasure same(Collection<E>) as another method in type BugExample". Reproducible: Always Steps to Reproduce: 1. Attempt to compile the above code in Helios.