FULL PRODUCT VERSION :
java version "1.8.0_71"
Java(TM) SE Runtime Environment (build 1.8.0_71-b15)
Java HotSpot(TM) Server VM (build 25.71-b15, mixed mode)
A DESCRIPTION OF THE PROBLEM :
In accordance with JLS 8.1.4, if type parameter name ("A", for example) of some class and other class name are equals then all occurrence "A" in type variable of generic superclass must be interpreted as type variable, not as class. But it is not.
public class Main {
public static class A {}
public static class MyList<A> extends java.util.ArrayList<A> {}
}
java 7
Compiled from "Main.java"
public class Main$MyList<A> extends java.util.ArrayList<A> {
public Main$MyList();
}
java 8
Compiled from "Main.java"
public class Main$MyList<A> extends java.util.ArrayList<Main$A> {
public Main$MyList();
}
REPRODUCIBILITY :
This bug can be reproduced always.
CUSTOMER SUBMITTED WORKAROUND :
Just rename type parameter.