Source parser bug
Bryce McKinlay
bryce@albatross.co.nz
Tue Jun 22 00:09:00 GMT 1999
Fully qualifing static methods sometimes produces an error message from
the source parser:
public class Parse
{
public static void main(String args[])
{
int i = java.lang.Integer.parseInt("20");
System.out.println(i);
}
}
[bryce@reason tests]$ gcj -c Parse.java -o parse --main=Parse
Parse.java: In class `Parse':
Parse.java: In method `main(java.lang.String[])':
Parse.java:5: Can't search method `parseInt' in package
`java.lang.Integer'.
int i = java.lang.Integer.parseInt("20");
Neither jikes nor javac have a problem with this code. It works fine if
the "java.lang" removed from the call.
regards
[ bryce ]
More information about the Java
mailing list