The Essence of Principal Typings

  • Authors:
  • J. B. Wells

  • Affiliations:
  • -

  • Venue:
  • ICALP '02 Proceedings of the 29th International Colloquium on Automata, Languages and Programming
  • Year:
  • 2002

Quantified Score

Hi-index 0.00

Visualization

Abstract

Let S be some type system. A typing in S for a typable term M is the collection of all of the information other than M which appears in the final judgement of a proof derivation showing that M is typable. For example, suppose there is a derivation in S ending with the judgement A 驴 M : 驴 meaning that M has result type 驴 when assuming the types of free variables are given by A. Then (A, 驴) is a typing for M. A principal typing in S for a term M is a typing for M which somehow represents all other possible typings in S for M. It is important not to confuse this with a weaker notion in connection with the Hindley/Milner type system often called"principal types". Previous definitions of principal typings for specific type systems have involvedv arious syntactic operations on typings such as substitution of types for type variables, expansion, lifting, etc.This paper presents a new general definition of principal typings which does not depend on the details of any particular type system. This paper shows that the new general definition correctly generalizes previous system-dependent definitions. This paper explains why the new definition is the right one. Furthermore, the new definition is used to prove that certain polymorphic type systems using 驴-quantifiers, namely System F and the Hindley/Milner system, do not have principal typings.All proofs can be foundin a longer version available at the author's home page.