JDK1.5 - More painful bugs aka Enumeration-Woes: Solved!
By Angsuman Chakraborty, Gaea News NetworkSunday, August 29, 2004
Current Status: Solved
Defect:
When more than one annotation type files are compiled in javac(any of the ways like *.java or @srclist or FileName1.java FileName2.java)
then it emits and error message that it cannot find symbol for statically imported Enums.
However statically importing one level up and de-referencing works.
Create two classes in the same directory as shown below to check the defect.
Just having any one of these files in the compilation list works fine. However more than one causes javac to croak!
//// Simple.java
import java.lang.annotation.Target;
import static java.lang.annotation.ElementType.*;
@Target (METHOD)
public @interface Simple {
String value();
}
//// Simple2.java
import java.lang.annotation.Target;
import static java.lang.annotation.ElementType.*;
@Target (TYPE)
public @interface Simple2 {
String value();
}
|
April 22, 2005: 2:22 pm
@Salu |
|
salu wedadu |
April 21, 2005: 6:20 am
i love java so much that i dont what to with my self. i would be very greateful if u allowed me to downloads your jdk1.5. thanx |
dayen