Why is usage of the (erased) generic type in right-hand side allowed during type casting in Java?

后端 未结 0 1095
無奈伤痛
無奈伤痛 2021-02-05 12:22

This is disallowed, which I believe is due to type erasure:

class Cup {
    private T t;
    public T[] getArray         


        
相关标签:
回答
  • 消灭零回复
提交回复
热议问题