Community
Participate
Working Groups
Found in I20050308-0835. The following code: class A< T > { enum E { v1, v2; } } class B extends A< Integer > { void a( A.E e ) { b( e ); // Warning here } void b( E e ) { } } Produces an unchecked conversion warning on the line indicated. The same code compiled with javac -Xlint:all produces no warnings. I've also had a few cases where mixing enums in a hierarchy with generics results in errors, which then disappear after a clean and rebuild is performed.
Please provide testcases for all of them. Then each distinct issue should have a separate defect.
I will, if I can manage to recreate them with a nice small code snippet. The one included above is as close as I've managed yet.
Unchecked warning should only arise if non static type being considered. Added EnumTest#test099. Fixed
will be released along with changes for bug 84496
*** Bug 91021 has been marked as a duplicate of this bug. ***
Verified in I20050510-0010