Proceedings of the 24th ACM SIGPLAN-SIGACT symposium on Principles of programming languages
Pizza into Java: translating theory into practice
Proceedings of the 24th ACM SIGPLAN-SIGACT symposium on Principles of programming languages
Making the future safe for the past: adding genericity to the Java programming language
Proceedings of the 13th ACM SIGPLAN conference on Object-oriented programming, systems, languages, and applications
Compatible genericity with run-time types for the Java programming language
Proceedings of the 13th ACM SIGPLAN conference on Object-oriented programming, systems, languages, and applications
Parametric polymorphism in Java: an approach to translation based on reflective features
OOPSLA '00 Proceedings of the 15th ACM SIGPLAN conference on Object-oriented programming, systems, languages, and applications
Design and implementation of generics for the .NET Common language runtime
Proceedings of the ACM SIGPLAN 2001 conference on Programming language design and implementation
Featherweight Java: a minimal core calculus for Java and GJ
ACM Transactions on Programming Languages and Systems (TOPLAS)
On Variance-Based Subtyping for Parametric Types
ECOOP '02 Proceedings of the 16th European Conference on Object-Oriented Programming
Formalization of generics for the .NET common language runtime
Proceedings of the 31st ACM SIGPLAN-SIGACT symposium on Principles of programming languages
Adding wildcards to the Java programming language
Proceedings of the 2004 ACM symposium on Applied computing
On the reification of Java wildcards
Science of Computer Programming
Proceedings of the 2011 ACM international conference on Object oriented programming systems languages and applications
Fast method dispatch and effective use of primitives for reified generics in managed X10
Proceedings of the 2012 ACM SIGPLAN X10 Workshop
Hi-index | 0.00 |
After several years from Sun Microsystems' call-for-proposals for adding generics to the Java Programming Language, JDK 1.5 will be finally shipped with a compile-time support for generics. However, differently e.g. from the current implementation of .NET Common Language Runtime, run-time support to generics - also commonly referred to as reification of type parameters - is not provided, leading to a number of well-known inadequacies which might potentially be critical. In this paper we present the EGO compiler (Exact Generics on Demand). This is the result of a project developed in collaboration with Sun Microsystems as an effort to provide run-time generics in a smooth way, without requiring any change on the JVM or on any other run-time support. The core solution is a sophisticated translation of code based on the type-passing style, where run-time type information is automatically created on a by-need basis, limiting as most as possible run-time overhead while retaining interoperability with legacy Java code. We present the main aspects of this development, from basic design to implementation and deployment issues. Many relevant aspects that typical raise when implementing advanced type systems over a mainstream programming language are discussed, shading light to some effective implementation techniques.