jdk-24/test/langtools/tools/javac/8203436/T8203436b.java
Maurizio Cimadamore 47d634e453 8203436: javac should fail early when emitting illegal signature attributes
Check that signature attributes do not contain non-denotable types

Reviewed-by: vromero
2018-05-22 13:37:05 +01:00

20 lines
396 B
Java

/*
* @test /nodynamiccopyright/
* @bug 8203436
* @summary javac should fail early when emitting illegal signature attributes
* @compile/fail/ref=T8203436b.out -XDrawDiagnostics T8203436b.java
*/
class T8203436b<X> {
interface A { }
interface B { }
class Inner { }
<Z extends A & B> T8203436b<Z> m() { return null; }
void test() {
m().new Inner() { };
}
}