z-logo
open-access-imgOpen Access
Polymorphic algebraic data type reconstruction
Author(s) -
Tom Schrijvers,
Maurice Bruynooghe
Publication year - 2006
Publication title -
lirias (ku leuven)
Language(s) - English
Resource type - Conference proceedings
ISBN - 1-59593-388-3
DOI - 10.1145/1140335.1140347
Subject(s) - programming language , type inference , computer science , soundness , programmer , data type , dependent type , rewriting , type (biology) , abstract data type , recursion (computer science) , functional programming , theoretical computer science , inference , lambda calculus , artificial intelligence , biology , ecology
One of the disadvantages of statically typed languages is the programmingoverhead caused by writing all the necessary type information: Both typedeclarations and type definitions are typically required. Traditional typeinference aims at relieving the programmer from the former.We present a rule-based constraint rewriting algorithm that reconstructs bothtype declarations and type definitions, allowing the programmer to effectivelyprogram type-less in a strictly typed language. This effectivelycombines strong points of dynamically typed languages (rapid prototyping)and statically typed ones (documentation, optimized compilation). Moreoverit allows to quickly port code from a statically untyped to a staticallytyped setting.Our constraint-based algorithm reconstructs uniform polymorphic definitions ofalgebraic data types and simultaneously infers the types of all expressions andfunctions (supporting polymorphic recursion) in the program. The declarativenature of the algorithm allows us to easily show that it has a number ofhighly desirable properties such as soundness, completeness and variousoptimality properties. Moreover, we show how to easily extend and adapt itto suit a number of different language constructs and type system features.status: publishe

The content you want is available to Zendy users.

Already have an account? Click here to sign in.
Having issues? You can contact us here
Accelerating Research

Address

John Eccles House
Robert Robinson Avenue,
Oxford Science Park, Oxford
OX4 4GP, United Kingdom