Substitution Polymorphism for Object-Oriented Programming

Authors

  • Jens Palsberg
  • Michael I. Schwartzbach

DOI:

https://doi.org/10.7146/dpb.v19i305.6698

Abstract

We introduce substitution polymorphism as a new basis for typed object-oriented languages. While avoiding subtypes and polymorphic types, this mechanism enables optimal static type-checking of generic classes and polymorphic functions. The novel idea is to view a class as having a family of implicit subclasses, each of which is obtained through a substitution of types. This allows instantiation of a generic class to be merely subclassing and resolves the problems in the Eiffel type system reported by Cook. All subclasses, including the implicit ones, can reuse the code implementing their superclass.

Author Biographies

Jens Palsberg

Michael I. Schwartzbach

Downloads

Published

1990-02-01

How to Cite

Palsberg, J., & Schwartzbach, M. I. (1990). Substitution Polymorphism for Object-Oriented Programming. DAIMI Report Series, 19(305). https://doi.org/10.7146/dpb.v19i305.6698