[자바] Type Erasure란 무엇인가?
자바에서 Type Erasure란 generic의 element type 정보를 컴파일 타임에만 조건을 확인하고 버려 런타임에는 element type 정보를 가지지 않는 것입니다. 왜 그렇게 하는가? 궁금증이 들어서 찾아봤습니다. 호환성 때문이라는 이야기도 있네요. 그런데 아래의 이야기가 맞지 않나 싶습니다. (stackoverflow.com/a/21840800/7225691) During the execution of a program, there should be no need for type information - this has already been verified by the compiler. 컴파일러 타임에 generic의 element type을 다 검증했기에 runtime에는 이러한 ..