Generative type abstraction and type-level computation

  • Authors:
  • Stephanie Weirich;Dimitrios Vytiniotis;Simon Peyton Jones;Steve Zdancewic

  • Affiliations:
  • University of Pennsylvania, Philadelphia, PA, USA;Microsoft Research, Cambridge, United Kingdom;Microsoft Research, Cambridge, United Kingdom;University of Pennsylvania, Philadelphia, PA, USA

  • Venue:
  • Proceedings of the 38th annual ACM SIGPLAN-SIGACT symposium on Principles of programming languages
  • Year:
  • 2011

Quantified Score

Hi-index 0.00

Visualization

Abstract

Modular languages support generative type abstraction, ensuring that an abstract type is distinct from its representation, except inside the implementation where the two are synonymous. We show that this well-established feature is in tension with the non-parametric features of newer type systems, such as indexed type families and GADTs. In this paper we solve the problem by using kinds to distinguish between parametric and non-parametric contexts. The result is directly applicable to Haskell, which is rapidly developing support for type-level computation, but the same issues should arise whenever generativity and non-parametric features are combined.