Community
Participate
Working Groups
the following code doesn't compile with eclipse : AbstractTest.java: package test; public abstract class AbstractTest<Z> { public abstract MyEnum m(Z z); public enum MyEnum { A,B } } Test.java: package test; import static test.AbstractTest.MyEnum.*; public class Test extends AbstractTest<String> { @Override public MyEnum m(String s) { return A; // <--- here } } This corectly compile without the import static or without the generics. The infered type of A is AbstractTest<Z>.MyEnum and not AbstractTest.MyEnum. It seems that eclipse doesn't considere that enum {} is a static context (the enum must not parametrized by Z) in case of static import. Rémi Forax
Which build are you using ? It works fine for me.
Checked with Eclipse 3.1.0.
Cannot reproduce.
Added StaticImportTest#test034
(In reply to comment #1) > Which build are you using ? It works fine for me. I20050627-1300 but works fine with : I20050627-1435 ok, thanx