![]() Get help with access Institutional accessĪccess to content on Oxford Academic is often provided through institutional subscriptions and purchases. The approach here presented turns out to be a significant alternative to the existing proposals for implementing generics in Java, supporting parametric types at run-time without unnecessary code footprint. Dynamic dispatching of method calls is supported by exploiting a data structure called the Virtual Parametric Methods Table, resembling Virtual Methods Tables of C++. Run-time efficiency is guaranteed thanks to a special treatment of descriptors deferring their creation at load-time. This is based on the management of method descriptors, which are objects passed to the method bodies at invocation-time, and which carry information on the instantiation of the method's type parameters. The main goal of this paper is to study a type-passing approach aimed at tackling these issues. Basically, type-erasure is unable to support parametric types at run-time, while code-expansion generally leads to significant increase of both disk and memory overhead. Up until now, only type-erasure and code-expansion have been exploited for the implementation of parametric methods, but they suffer from some problems. Existing proposals for extending Java with parametric polymorphism are outlined, showing and discussing the basic implementation techniques: type-erasure, code-expansion and type-passing. his paper focuses on their implementation techniques for Java. ![]() ![]() Parametric methods are recognized as a very useful tool for reusing code and augmenting the expressiveness of an object-oriented language providing parametric classes.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |