Principal Type Schemes for Functional Programs with Overloading and Subtyping

@article{Smith1994PrincipalTS,
  title={Principal Type Schemes for Functional Programs with Overloading and Subtyping},
  author={Geoffrey Smith},
  journal={Sci. Comput. Program.},
  year={1994},
  volume={23},
  pages={197-226}
}
  • Geoffrey Smith
  • Published 1 December 1994
  • Computer Science
  • Sci. Comput. Program.

Figures from this paper

Optimal Representations of Polymorphic Types with Subtyping (Extended Abstract)
TLDR
An algorithm for simplifying quantified types in the presence of subtyping is presented and it is proved it is sound and complete for non-recursive and recursive types.
Optimal Representations of Polymorphic Types with Subtyping
TLDR
An algorithm for simplifying quantified types in the presence of subtyping is presented and it is proved it is sound and complete for non-recursive and recursive types and an extension is shown that an extension of the algorithm is sound but not complete for a type language with intersection and union types.
Pragmatic subtyping in polymorphic languages
TLDR
A partial type inference algorithm for the extended Hindley/Milner type system which favours succinctness over generality, in the sense that it never infers types with subtype constraints.
Polymorphism, subtyping, and type inference in MLsub
TLDR
A type system combining subtyping and ML-style parametric polymorphism that supports type inference and has compact principal types is presented, which types a strict superset of core ML programs.
Type inference in systems of recursive types with subtyping
TLDR
The type inference algorithm generalizes a common idea of previous work: type inference is reduced to a constraint satisfaction problem, whose satisfiability can be decided by a process of closure and consistency checking, and a general correctness theorem is proved.
Constraint Abstractions
TLDR
The constraint language with constraint abstractions is extended so that instantiation can be expressed directly in the constraint language and a cubic-time algorithm for constraint solving is given.
Polymorphic Subtyping for Effect Analysis: The Static Semantics
TLDR
This paper integrates all of polymorphism, effects, and subtyping into an annotated type and effect system for Concurrent ML and shows that the resulting system is a conservative extension of the ML type system.
Type Inference for GADTs and Anti-unification
TLDR
A type inference algorithm for GADTs is presented that is based on a closed-world approach to overloading and uses anti-unification and constraint-set satisfiability to infer the relationship between the types of function arguments and result.
Subtyping Constrained Types
TLDR
This paper develops several subtyping relations on polymorphic constrained types of a general form that allows recursive constraints and multiple bounds on type variables.
Type inference in systems of recursive types withsubtypingTrevor
TLDR
The type inference algorithm generalizes a common idea of previous work and proves a general correctness theorem for this style of type inference, which provides deenitions of closure and consistency for recursive types with a greatest type, but not a least type.
...
...

References

SHOWING 1-10 OF 24 REFERENCES
Type Reconstruction with Recursive Types and Atomic Subtyping
TLDR
This work considers the problem of type reconstruction for A-terms over a type system with recursive types and atomic subsumptions and shows how to solve such inequalities by reduction to an infinite but well-structured set of inequalities over the base types.
Parametric Overloading in Polymorphic Programming Languages
TLDR
This paper defines the concept of parametric overloading as a restricted form of overloading which is easily combined with parametric polymorphism, thereby allowing the design of efficient type inference algorithms.
Polymorphic Type Inference for Languages with Overloading and Subtyping
TLDR
This dissertation extends the Hindley/Milner/Damas type system to incorporate overloading and subtyping, and proves that it is undecidable whether a given constraint set is satisfiable; this difficulty leads us to impose restrictions on overloading.
Coercion and type inference
TLDR
A simple semantic model of automatic coercion is proposed and an efficient type checking algorithm based on the first four rules is presented that is guaranteed to find a type whenever a type can be deduced using the four inference rules.
Three Approaches to Type Structure
We examine three disparate views of the type structure of programming languages: Milner's type deduction system and polymorphic let construct, the theory of subtypes and generic operators, and the
Type Inference with Subtypes
Type inference with subtypes
TLDR
A type system for deriving types of expressions in the language and an algorithm for type inference in a language with functions, records, and variant records is given, which is a synthesis of subtype polymorphism and universal polymorphism.
Polymorphic Subtype Inference: Closing the Theory-Practice Gap
TLDR
Following the framework described above, a transformation is described, based on the lazy instance definition, that eliminates certain redundancies from typings that leads to a coercion set of size at most one.
Constrained Quantification in Polymorphic Type Analysis
TLDR
It is claimed that constrained quantification is a flexible, powerful, practical and formally comprehensible approach to polymorphic type analysis, especially when applied to languages with non-trivial subtyping.
On the Complexity of ML Typability with Overloading
TLDR
It is shown that under a correct notion of well-typed terms, the problem of determining whether a term is well typed with respect to an assumption set in an ML-style type system is undecidable, and a limited form of recursion called parametric recursion is considered.
...
...