test/langtools/tools/javac/generics/GetClass.java
author erikj
Tue, 12 Sep 2017 19:03:39 +0200
changeset 47216 71c04702a3d5
parent 30721 langtools/test/tools/javac/generics/GetClass.java@1024d425d97e
permissions -rw-r--r--
8187443: Forest Consolidation: Move files to unified layout Reviewed-by: darcy, ihse

/*
 * @test /nodynamiccopyright/
 * @bug 4919255 4982096 5004321
 * @summary the type of x.getClass() is no longer Class<? extends X>
 * @author gafter
 *
 * @compile/fail/ref=GetClass.out -XDrawDiagnostics  GetClass.java
 */

public class GetClass {
    public static void main(String[] args) {
        Class<? extends Class<GetClass>> x = GetClass.class.getClass();
    }
}