类型擦除是计算机程序设计时,在编译期明确去掉所编程序(某部分)的类型系统。
例如,将象List这样的泛型类型擦除得只剩下List。
For example, a generic type such as List is erased to simply List.
因为Tiger依靠类型擦除,所以数据类型转换和instance of测试中的外露类型参数被“擦除”为它们的上界(在前面的例子中,那将是类型Object)。
Because Tiger relies on type erasure, the naked type parameters in casts and instanceof tests are "erased" to their upper bounds (in the earlier case, that'll be type Object).
这两种内存类型在擦除块方面有所不同。
The process of erasing a block differs between the two memory types.
应用推荐