Name: laC46010 Date: 01/20/97
The test below causes compiler crash (both jdk1.1beta2 and jdk1.1beta3).
jdk1.0.2 reports a proper syntax error.
e.java:
class e {
void () {}
}
/home/leo/java/bug> /export/ld32/dest/jdk1.1beta3/solaris/bin/javac e.java
sun.tools.java.CompilerError: getClassName:void
at sun.tools.java.Type.getClassName(Type.java)
at sun.tools.javac.BatchParser.defineField(BatchParser.java)
at sun.tools.java.Parser.parseField(Parser.java)
at sun.tools.java.Parser.parseClassBody(Parser.java)
at sun.tools.java.Parser.parseNamedClass(Parser.java)
at sun.tools.java.Parser.parseClass(Parser.java)
at sun.tools.java.Parser.parseFile(Parser.java)
at sun.tools.javac.BatchEnvironment.parseFile(BatchEnvironment.java)
at sun.tools.javac.Main.compile(Main.java)
at sun.tools.javac.Main.main(Main.java)
error: An error has occurred in the compiler; please file a bug report (###@###.###).
1 error
======================================================================