Results 1  10
of
14
Putting Type Annotations to Work
, 1996
"... We study an extension of the HindleyMilner system with explicit type scheme annotations and type declarations. The system can express polymorphic function arguments, userdefined data types with abstract components, and structure types with polymorphic fields. More generally, all programs of the po ..."
Abstract

Cited by 96 (1 self)
 Add to MetaCart
We study an extension of the HindleyMilner system with explicit type scheme annotations and type declarations. The system can express polymorphic function arguments, userdefined data types with abstract components, and structure types with polymorphic fields. More generally, all programs of the polymorphic lambda calculus can be encoded by a translation between typing derivations. We show that type reconstruction in this system can be reduced to the decidable problem of firstorder unification under a mixed prefix.
Equational Reasoning for Linking with FirstClass Primitive Modules
 In European Symposium on Programming
, 2000
"... . Modules and linking are usually formalized by encodings which use the calculus, records (possibly dependent), and possibly some construct for recursion. In contrast, we introduce the mcalculus, a calculus where the primitive constructs are modules, linking, and the selection and hiding of mo ..."
Abstract

Cited by 27 (5 self)
 Add to MetaCart
. Modules and linking are usually formalized by encodings which use the calculus, records (possibly dependent), and possibly some construct for recursion. In contrast, we introduce the mcalculus, a calculus where the primitive constructs are modules, linking, and the selection and hiding of module components. The mcalculus supports smooth encodings of software structuring tools such as functions ( calculus), records, objects (&calculus), and mutually recursive definitions. The mcalculus can also express widely varying kinds of module systems as used in languages like C, Haskell, and ML. We prove the mcalculus is confluent, thereby showing that equational reasoning via the mcalculus is sensible and well behaved. 1 Introduction A long version of this paper [43] which contains full proofs, more details and explanations, and comparisons with more calculi (including the calculus of Ancona and Zucca [4]), is available at http://www.cee.hw.ac.uk/~jbw/papers/. 1.1 Support f...
A constraintbased approach to guarded algebraic data types
 ACM Trans. Prog. Languages Systems
, 2007
"... We study HMG(X), an extension of the constraintbased type system HM(X) with deep pattern matching, polymorphic recursion, and guarded algebraic data types. Guarded algebraic data types subsume the concepts known in the literature as indexed types, guarded recursive datatype constructors, (firstcla ..."
Abstract

Cited by 24 (0 self)
 Add to MetaCart
We study HMG(X), an extension of the constraintbased type system HM(X) with deep pattern matching, polymorphic recursion, and guarded algebraic data types. Guarded algebraic data types subsume the concepts known in the literature as indexed types, guarded recursive datatype constructors, (firstclass) phantom types, and equality qualified types, and are closely related to inductive types. Their characteristic property is to allow every branch of a case construct to be typechecked under different assumptions about the type variables in scope. We prove that HMG(X) is sound and that, provided recursive definitions carry a type annotation, type inference can be reduced to constraint solving. Constraint solving is decidable, at least for some instances of X, but prohibitively expensive. Effective type inference for guarded algebraic data types is left as an issue for future research.
ConstraintBased Type Inference for Guarded Algebraic Data Types
, 2003
"... Guarded algebraic data types, which subsume the concepts known in the literature as indexed types, guarded recursive datatype constructors, and phantom types, and are closely related to inductive types, have the distinguishing feature that, when typechecking a function defined by cases, every branch ..."
Abstract

Cited by 23 (3 self)
 Add to MetaCart
Guarded algebraic data types, which subsume the concepts known in the literature as indexed types, guarded recursive datatype constructors, and phantom types, and are closely related to inductive types, have the distinguishing feature that, when typechecking a function defined by cases, every branch must be checked under di#erent typing assumptions. This mechanism allows exploiting the presence of dynamic tests in the code to produce extra static type information.
The Design and Implementation of Mondrian
 In Proceedings of the Haskell Workshop
, 1997
"... The Haskell dialect Mondrian is designed using the explicit philosophy of keeping things simple and consistent. Mondrian generalizes some of Haskell's (too) complex constructs, and adds a few simple new ones. This results in a small, intuitively comprehensible language with an object oriented f ..."
Abstract

Cited by 19 (4 self)
 Add to MetaCart
The Haskell dialect Mondrian is designed using the explicit philosophy of keeping things simple and consistent. Mondrian generalizes some of Haskell's (too) complex constructs, and adds a few simple new ones. This results in a small, intuitively comprehensible language with an object oriented flavor. In this paper, we will present the design decisions we made for Mondrian. Furthermore, some of Mondrian's language constructs will be defined by translations into Haskell. 1 Introduction In the preface of the Haskell report [13] the hope is expressed that extensions or variants of the language will appear that incorporate experimental features. The language Mondrian is such an experiment. Mondrian evolved from Haskell by deleting and combining some of Haskell's more complicated constructs and adding a few simple new ones. Unlike the language Pizza [29], which is designed as a strict superset of Java [8], the major concern in designing Mondrian has been to keep the language as basic and do...
Confluent Equational Reasoning for Linking with FirstClass Primitive Modules
 In ESOP 2000  European Symposium on Programming 2000, number 1782 in Lecture Notes in Computer Science
, 1999
"... Modules and linking are usually formalized by encodings which use the lambda calculus, records (possibly dependent), and possibly some construct for recursion. In contrast, we present the mcalculus, a calculus where the primitive constructs are modules, linking, and the selection and hiding of modu ..."
Abstract

Cited by 17 (3 self)
 Add to MetaCart
Modules and linking are usually formalized by encodings which use the lambda calculus, records (possibly dependent), and possibly some construct for recursion. In contrast, we present the mcalculus, a calculus where the primitive constructs are modules, linking, and the selection and hiding of module components. In addition to supporting equational reasoning about modules and linking, the mcalculus allows smooth encodings of software structuring tools such as the lambda calculus, mutually recursive definitions, records (including operations like extension and concatenation), and objects. The mcalculus is extremely well behaved  we show not only that the mcalculus is confluent but also that it satisfies the strong finite developments property.
Extensible records with scoped labels
 In: Proceedings of the 2005 Symposium on Trends in Functional Programming
, 2005
"... Records provide a safe and flexible way to construct data structures. We describe a natural approach to typing polymorphic and extensible records that is simple, easy to use in practice, and straightforward to implement. A novel aspect of this work is that records can contain duplicate labels, effec ..."
Abstract

Cited by 4 (0 self)
 Add to MetaCart
Records provide a safe and flexible way to construct data structures. We describe a natural approach to typing polymorphic and extensible records that is simple, easy to use in practice, and straightforward to implement. A novel aspect of this work is that records can contain duplicate labels, effectively introducing a form of scoping over the labels. Furthermore, it is a fully orthogonal extension to existing type systems and programming languages. In particular, we show how it can be used conveniently with standard HindleyMilner, qualified types, and MLF. 1
TypeSecure MetaProgramming
, 1998
"... DataTypes : : : : : : : : : : : : : : : : : : : : : : : : : 40 4.2 PolymorphicDataTypes : : : : : : : : : : : : : : : : : : : : : : : 40 vi 4.3 Existential DataTypes : : : : : : : : : : : : : : : : : : : : : : : : 41 4.4 DynamicTypes : : : : : : : : : : : : : : : : : : : : : : : : : : : : 43 4.5 Dy ..."
Abstract

Cited by 3 (0 self)
 Add to MetaCart
DataTypes : : : : : : : : : : : : : : : : : : : : : : : : : 40 4.2 PolymorphicDataTypes : : : : : : : : : : : : : : : : : : : : : : : 40 vi 4.3 Existential DataTypes : : : : : : : : : : : : : : : : : : : : : : : : 41 4.4 DynamicTypes : : : : : : : : : : : : : : : : : : : : : : : : : : : : 43 4.5 Dynamic Semantics : : : : : : : : : : : : : : : : : : : : : : : : : : 45 5 A Tiny Programming Language 48 5.1 Tiny Layout Conventions : : : : : : : : : : : : : : : : : : : : : : 48 5.2 Existential Type Variables : : : : : : : : : : : : : : : : : : : : : : 50 5.3 Type Signatures withHoles : : : : : : : : : : : : : : : : : : : : : 50 5.4 PolymorphicAbstractions : : : : : : : : : : : : : : : : : : : : : : 51 5.5 TopLevel Function Signatures : : : : : : : : : : : : : : : : : : : : 53 5.6 AlgebraicDataTypes : : : : : : : : : : : : : : : : : : : : : : : : 54 5.7 Restricted Type Synonyms and Newtype : : : : : : : : : : : : : : 55 5.8 Summary of Type System : : : : : : : : : : : : : : : : : : : : : : 56 5.9 DynamicTypes : : : : : : : : : : : : : : : : : : : : : : : : : : : : 57 6 Systems Programming with Dynamic Types 59 6.1 Error Handling : : : : : : : : : : : : : : : : : : : : : : : : : : : : 59 6.2 InterProcess Communication : : : : : : : : : : : : : : : : : : : : 62 6.3 A Simple Address Server : : : : : : : : : : : : : : : : : : : : : : : 64 6.4 A Simple File Server : : : : : : : : : : : : : : : : : : : : : : : : : 66 6.5 A Capability System : : : : : : : : : : : : : : : : : : : : : : : : : 69 6.6 Distributed InterProcess Communication : : : : : : : : : : : : : 75 6.7 A Compiler Interface : : : : : : : : : : : : : : : : : : : : : : : : : 78 6.8 AFunctional Compiler Interface : : : : : : : : : : : : : : : : : : 81 7 Dynamic Overloading 83 7.1 Dynamically Resolved Overloading : : ...
An Exploration of Modular Programs
 In Glasgow Workshop on Functional Programming
, 1996
"... Recently, Mark Jones introduced first class structures as a means to express modular structure. In this paper we elaborate on this idea by comparing the module systems of Standard ML and Haskell 1.3, two widely used functional languages, and a Haskell variant equipped with such first class structure ..."
Abstract

Cited by 2 (0 self)
 Add to MetaCart
Recently, Mark Jones introduced first class structures as a means to express modular structure. In this paper we elaborate on this idea by comparing the module systems of Standard ML and Haskell 1.3, two widely used functional languages, and a Haskell variant equipped with such first class structures. Moreover, we look at another obvious and wellknown extension to HindleyMilner type systems, namely higher order type variables, to explore its usefulness in solving problems occuring when one attempts to structure larger programs into maintainable pieces. We argue that there are surprisingly few applications where the module system currently provided by Haskell cannot keep pace with Standard ML's expressiveness. When one adds first class structures to Haskell, the module system reaches the expressiveness of Standard ML and even exceeds it. 1 Preliminaries It is widely agreed that modular programming (in the sense of using small program units, or modules, to construct more sophisticated...
A Rendezvous of Functions and Reactive Objects  Escaping the Evil
 I, Proceedings of Haskell Workshop
, 1997
"... We present an extension to Haskell which supports reactive, concurrent programming with objects, sans the problematic blocking input. We give a semantics together with a number of programming examples, and show an implementation based on a preprocessor, and a library written in Concurrent Haskell. 1 ..."
Abstract

Cited by 1 (0 self)
 Add to MetaCart
We present an extension to Haskell which supports reactive, concurrent programming with objects, sans the problematic blocking input. We give a semantics together with a number of programming examples, and show an implementation based on a preprocessor, and a library written in Concurrent Haskell. 1 Introduction With the advent of Haskell 1.3 the monadic I/O model has become well established [Pe96]. At the top level, a Haskell program is now a sequence of imperative commands that transforms a state consisting of the real world and/or some program state into a final configuration. In a pure state transformational approach, carrying a monolithic program state around is likely to complicate modular design; however, this problem can to a large extent be circumvented by introducing firstclass references in the monadic framework [LPJ94]. Taken together, these additions make the resulting Haskell programs  on the top level at least  more and more reminiscent of programs written in tra...