Community
Participate
Working Groups
Build Identifier: 20100917-0705 The test code: import java.util.List; public class TestMain { public String getInfo(List<String> data) { return ""; } public String getInfo(List<Integer> data) { return ""; } } Eclipse doesn't compiles the code and outputs the error: "Method getInfo(List<Integer>) has the same erasure getInfo(List<E>) as another method in type TestMain" However java and Idea compile the code fine. Reproducible: Always Steps to Reproduce: 1. Write the code: import java.util.List; public class TestMain { public String getInfo(List<String> data) { return ""; } public String getInfo(List<Integer> data) { return ""; } } 2. Try to run or compile it.
*** This bug has been marked as a duplicate of bug 317719 ***
junit has been added as a part of the fix for bug 317719
I think this was wrongly marked as dup. This is invalid because the given code neither compiles with java6 nor with java7. (and hence also not with ECJ in 1.6 or 1.7 compliances).
Verified using build M20110824-0800.