Section: New Results
Extending ML with (impredicative) second-order types
The ML language uses simple types (first-order types without quantifiers) enriched with type schemes (simple types with outer-most universal quantifiers). This allows for simple type inference based on first-order unification, relieving the user from the burden of writing type annotations. However, it supports only a limited form of parametric polymorphism. In contrast, System F uses second-order types (types with inner universal quantifiers at arbitrary depth) that are much more expressive. As a result, type inference is undecidable in System F, which forces the user to provide all type annotations.
Didier Le Botlan and Didier Rémy proposed a type system, called MLF, that enables type synthesis as in ML while retaining the expressiveness of System F  . Only type annotations on parameters of functions that are used polymorphically in their body are required. All other type annotations, including all type abstractions and type applications are inferred. Remarkably, type inference in MLF reduces to a new form of unification that amounts to performing first-order unification in the presence of second-order types.
The initial study of MLF was the topic of Didier Le Botlan's PhD dissertation  . Didier Le Botlan and Didier Rémy have continued their work on MLF focusing on the simplification of the formalism. An interesting restriction of MLF that retains most of its expressiveness while being simpler and more intuitive allows to provide a semantics of types as sets of System-F types and so to pull back the definition of type-instantiation from set inclusion on the semantics of types. This justifies a posteriori the type-instance relation of MLF that was previously defined only by syntactic means. This work has been submitted for journal publication.
Boris Yakobowski, who started his PhD under Didier Rémy's supervision in October 2004, is pursuing the investigation of MLF, and especially of MLF types, using graphs rather than terms, so as to eliminate most of the notational redundancies. Graph types are the superposition of a DAG representation of first-order terms and a binding tree that describes where and how variables are bound. This representation is much more canonical than syntactic types. It led to the discovery of a linear-time unification algorithm on graph types, which can be decomposed into standard first-order unification on the underlying dags and a simple computation on the underlying binding trees. These results will be presented at the workshop on Types in Language Design and Implementation (TLDI 07)  . An extended version with detailed proofs is available as a technical report  .