df82d9a4b5
Preventing NullPointerException when a class has an erroneous supertype and does not have an implementation of the equals method. Reviewed-by: darcy, vromero
13 lines
410 B
Java
13 lines
410 B
Java
/*
|
|
* @test /nodynamiccopyright/
|
|
* @bug 8242802
|
|
* @summary Verify javac does not crash while checking for equals/hashCode overrides
|
|
* @compile/fail/ref=InvalidAnonymous.out -XDrawDiagnostics InvalidAnonymous.java
|
|
* @compile/fail/ref=InvalidAnonymous.out -XDrawDiagnostics -Xlint:overrides InvalidAnonymous.java
|
|
*/
|
|
public class InvalidAnonymous {
|
|
private void t() {
|
|
new Undefined() {};
|
|
}
|
|
}
|