Matching ThisType to subtyping

  • Authors:
  • Chieri Saito;Atsushi Igarashi

  • Affiliations:
  • Kyoto University, Kyoto Japan;Kyoto University, Kyoto Japan

  • Venue:
  • Proceedings of the 2009 ACM symposium on Applied Computing
  • Year:
  • 2009

Quantified Score

Hi-index 0.00

Visualization

Abstract

The notion of ThisType has been proposed to promote typesafe reuse of binary methods and recently extended to mutually recursive definitions. It is well-known, however, that ThisType does not match with subtyping well. In the current type systems, type safety is guaranteed by the sacrifice of subtyping, hence dynamic dispatch. In this paper, we propose two mechanisms, namely, nonheritable methods and local exactization to remedy the mismatch between ThisType and subtyping. We rigorously prove their safety by modeling them in a small calculus.