import java.util.List; abstract class B { void foo(List[]> x) { Object y1 = (List[]>)x; } void foo1(List>[]> x) { Object y1 = (List>[]>)x; } void foo2(List x) { Object y1 = (List)x; } }