Community
Participate
Working Groups
Build ID: M20090211-1700 Steps To Reproduce: public enum Enun { A(STATIK); private static int STATIK = 1; private Enun(final int i) { } } More information:
*** This bug has been marked as a duplicate of bug 263877 ***
Since the forward reference is via a simple name, it must be complained against per 8.3.2.3 of JLS3.0. I get the same error with java 1.5 and java 1.6 ("Illegal forward reference"), so the reported behavior (cannot reference a field ...) matches javac behavior and the spec. See also bug 273990.
Verified for 3.5M7 using I20090426-2000