Results 1 -
2 of
2
Incremental Polymorphic Type Checking With Update
, 1992
"... We describe a variant of Milner's ML type inference algorithm which can be used to perform incremental type checking of programs with partially unspecied functions (or predicates in Prolog). This supports modication (e.g. for correction) of procedures dened previously and provides for a convenient t ..."
Abstract
-
Cited by 2 (0 self)
- Add to MetaCart
We describe a variant of Milner's ML type inference algorithm which can be used to perform incremental type checking of programs with partially unspecied functions (or predicates in Prolog). This supports modication (e.g. for correction) of procedures dened previously and provides for a convenient treatment of top-level mutual recursion including Prolog-style incremental clausal denition. The system allows us to: dene a function of, say, type ! , use it in suceeding functions and then modify its denition to a type instance, such as list( int) ! list( int), provided that, in the meantime, it has not been used by other functions at an incompatible instance. Undened procedures can be treated as having type (or ! corresponding to the function x:fail ). This is useful for the case of languages (like HOPE, Miranda, Haskell and Prolog) which require that all top-level procedures are dened mutually recursively | forward references can then be treated as if dened by x...
Typed Constraint Logic Programs: checking domain coercions and metaprograms through subtyping
"... We propose a general prescriptive type system with parametric polymorphism and subtyping for constraint logic programs. The aim of this type system is to detect programming errors statically. It introduces a type discipline for constraint logic programs and modules, while maintaining the capabilitie ..."
Abstract
- Add to MetaCart
We propose a general prescriptive type system with parametric polymorphism and subtyping for constraint logic programs. The aim of this type system is to detect programming errors statically. It introduces a type discipline for constraint logic programs and modules, while maintaining the capabilities of performing the usual coercions between constraint domains and of typing meta-programming predicates, thanks to the flexibility of subtyping. The property of subject reduction expresses the consistency of the type system w.r.t. the execution model: if a program is "well-typed", then all derivations starting in a "well-typed" goal are again "well-typed". That property is proved w.r.t. the abstract execution model of constraint programming which proceeds by accumulation of constraints. We describe our implementation of the system for type checking and type inference. We report our experimental results on type checking the libraries of Sicstus Prolog and other Prolog programs....

