Results 1  10
of
87
Subtyping recursive types
 ACM TRANSACTIONS ON PROGRAMMING LANGUAGES AND SYSTEMS
, 1993
"... We investigate the interactions of subtyping and recursive types, in a simply typed λcalculus. The two fundamental questions here are whether two (recursive) types are in the subtype relation, and whether a term has a type. To address the first question, we relate various definitions of type equiva ..."
Abstract

Cited by 310 (8 self)
 Add to MetaCart
We investigate the interactions of subtyping and recursive types, in a simply typed λcalculus. The two fundamental questions here are whether two (recursive) types are in the subtype relation, and whether a term has a type. To address the first question, we relate various definitions of type equivalence and subtyping that are induced by a model, an ordering on infinite trees, an algorithm, and a set of type rules. We show soundness and completeness between the rules, the algorithm, and the tree semantics. We also prove soundness and a restricted form of completeness for the model. To address the second question, we show that to every pair of types in the subtype relation we can associate a term whose denotation is the uniquely determined coercion map between the two types. Moreover, we derive an algorithm that, when given a term with implicit coercions, can infer its least
Simple TypeTheoretic Foundations for ObjectOriented Programming
, 1993
"... We develop a formal, typetheoretic account of the basic mechanisms of objectoriented programming: encapsulation, message passing, subtyping, and inheritance. By modeling object encapsulation in terms of existential types instead of the recursive records used in other recent studies, we obtain a s ..."
Abstract

Cited by 159 (17 self)
 Add to MetaCart
We develop a formal, typetheoretic account of the basic mechanisms of objectoriented programming: encapsulation, message passing, subtyping, and inheritance. By modeling object encapsulation in terms of existential types instead of the recursive records used in other recent studies, we obtain a substantial simplification both in the model of objects and in the underlying typed calculus.
Operations on records
 Mathematical Structures in Computer Science
, 1991
"... We define a simple collection of operations for creating and manipulating record structures, where records are intended as finite associations of values to labels. A secondorder type system over these operations supports both subtyping and polymorphism. We provide typechecking algorithms and limite ..."
Abstract

Cited by 143 (13 self)
 Add to MetaCart
We define a simple collection of operations for creating and manipulating record structures, where records are intended as finite associations of values to labels. A secondorder type system over these operations supports both subtyping and polymorphism. We provide typechecking algorithms and limited semantic models. Our approach unifies and extends previous notions of records, bounded quantification, record extension, and parametrization by rowvariables. The general aim is to provide foundations for concepts found in objectoriented languages, within a framework based on typed lambdacalculus.
PolyTOIL: A typesafe polymorphic objectoriented language
, 1995
"... PolyTOIL is a new staticallytyped polymorphic objectoriented programming language that is provably typesafe. By separating the de nitions of subtyping and inheritance, providing a name for the type of self, and carefully de ning the typechecking rules, we have obtained a language that is ve ..."
Abstract

Cited by 139 (10 self)
 Add to MetaCart
PolyTOIL is a new staticallytyped polymorphic objectoriented programming language that is provably typesafe. By separating the de nitions of subtyping and inheritance, providing a name for the type of self, and carefully de ning the typechecking rules, we have obtained a language that is very expressive while supporting modular typechecking of classes. The matching relation on types, which is related to Fbounded quanti cation, is used both in stating typechecking rules and expressing the bounds on type parameters for polymorphism. The design of PolyTOIL is based on a careful formal de nition of typechecking rules and semantics.
A Calculus for Overload Functions with Subtyping

, 1992
"... We present a simple extension of typed calculus where functions can be overloaded by putting different "branches of code" together. When the function is applied, the branch to execute is chosen according to a particular selection rule which depends on the type of the argument. The cru ..."
Abstract

Cited by 139 (28 self)
 Add to MetaCart
We present a simple extension of typed calculus where functions can be overloaded by putting different "branches of code" together. When the function is applied, the branch to execute is chosen according to a particular selection rule which depends on the type of the argument. The crucial feature of the present approach is that the branch selection depends on the "runtime type" of the argument, which may differ from its compiletime type, because of the existence of a subtyping relation among types. Hence overloading cannot be eliminated by a static analysis of code, but is an essential feature to be dealt with during computation. We obtain in this way a typedependent calculus, which differs from the various calculi where types do not play any role during computation. We prove Confluence and a generalized SubjectReduction theorem for this calculus. We prove Strong Normalization for a "stratified" subcalculus. The definition of this calculus is guided by the understand...
Inheritance As Implicit Coercion
 Information and Computation
, 1991
"... . We present a method for providing semantic interpretations for languages with a type system featuring inheritance polymorphism. Our approach is illustrated on an extension of the language Fun of Cardelli and Wegner, which we interpret via a translation into an extended polymorphic lambda calculus. ..."
Abstract

Cited by 120 (3 self)
 Add to MetaCart
. We present a method for providing semantic interpretations for languages with a type system featuring inheritance polymorphism. Our approach is illustrated on an extension of the language Fun of Cardelli and Wegner, which we interpret via a translation into an extended polymorphic lambda calculus. Our goal is to interpret inheritances in Fun via coercion functions which are definable in the target of the translation. Existing techniques in the theory of semantic domains can be then used to interpret the extended polymorphic lambda calculus, thus providing many models for the original language. This technique makes it possible to model a rich type discipline which includes parametric polymorphism and recursive types as well as inheritance. A central difficulty in providing interpretations for explicit type disciplines featuring inheritance in the sense discussed in this paper arises from the fact that programs can typecheck in more than one way. Since interpretations follow the type...
A Paradigmatic ObjectOriented Programming Language: Design, Static Typing and Semantics
 Journal of Functional Programming
, 1993
"... In order to illuminate the fundamental concepts involved in objectoriented programming languages, we describe the design of TOOPL, a paradigmatic, staticallytyped, functional, objectoriented programming language which supports classes, objects, methods, hidden instance variables, subtypes, and in ..."
Abstract

Cited by 117 (9 self)
 Add to MetaCart
In order to illuminate the fundamental concepts involved in objectoriented programming languages, we describe the design of TOOPL, a paradigmatic, staticallytyped, functional, objectoriented programming language which supports classes, objects, methods, hidden instance variables, subtypes, and inheritance. It has proven to be quite difficult to design such a language which has a secure type system. A particular problem with statically type checking objectoriented languages is designing typechecking rules which ensure that methods provided in a superclass will continue to be type correct when inherited in a subclass. The typechecking rules for TOOPL have this feature, enabling library suppliers to provide only the interfaces of classes with actual executable code, while still allowing users to safely create subclasses. In order to achieve greater expressibility while retaining typesafety, we choose to separate the inheritance and subtyping hierarchy in the language. The design of...
An extension of system F with subtyping
 Information and Computation
, 1991
"... System F is a wellknown typed lcalculus with polymorphic types, which provides a basis for polymorphic programming languages. We study an extension of F, called F <: (pronounced efsub) that combines parametric polymorphism with subtyping. The main focus of the paper is the equational theory of ..."
Abstract

Cited by 114 (11 self)
 Add to MetaCart
System F is a wellknown typed lcalculus with polymorphic types, which provides a basis for polymorphic programming languages. We study an extension of F, called F <: (pronounced efsub) that combines parametric polymorphism with subtyping. The main focus of the paper is the equational theory of F <: , which is related to PER models and the notion of parametricity. We study some categorical properties of the theory when restricted to closed terms, including interesting categorical isomorphisms. We also investigate prooftheoretical properties, such as the conservativity of typing judgments with respect to F. We demonstrate by a set of examples how a range of constructs may be encoded in F <: . These include record operations and subtyping hierarchies that are related to features of objectoriented languages. Appears in: International Conference on Theoretical Aspects of Computer Software, T.Ito, A.R.Meyer Eds., Lecture Notes in Computer Science n. 526, pp 750770, Springer Verlag, 19...
Bounded Quantification is Undecidable
 Information and Computation
, 1993
"... F is a typed calculus with subtyping and bounded secondorder polymorphism. First proposed by Cardelli and Wegner, it has been widely studied as a core calculus for type systems with subtyping. Curien and Ghelli proved the partial correctness of a recursive procedure for computing minimal types of ..."
Abstract

Cited by 102 (9 self)
 Add to MetaCart
F is a typed calculus with subtyping and bounded secondorder polymorphism. First proposed by Cardelli and Wegner, it has been widely studied as a core calculus for type systems with subtyping. Curien and Ghelli proved the partial correctness of a recursive procedure for computing minimal types of F terms and showed that the termination of this procedure is equivalent to the termination of its major component, a procedure for checking the subtype relation between F types. This procedure was thought to terminate on all inputs, but the discovery of a subtle bug in a purported proof of this claim recently reopened the question of the decidability of subtyping, and hence of typechecking. This question is settled here in the negative, using a reduction from the halting problem for twocounter Turing machines to show that the subtype relation of F is undecidable. 1 Introduction The notion of bounded quantification was introduced by Cardelli and Wegner [16] in the language Fun. Based on i...
Programming with Intersection Types and Bounded Polymorphism
, 1991
"... representing the official policies, either expressed or implied, of the U.S. Government. ..."
Abstract

Cited by 67 (4 self)
 Add to MetaCart
representing the official policies, either expressed or implied, of the U.S. Government.