ACM Home Page
Please provide us with feedback. Feedback
On understanding types, data abstraction, and polymorphism
Full text PdfPdf (4.20 MB)
Blog Information Rambling on Software: Understanding Types
Dr. Terry J Coatta (07/13/2008)
Source ACM Computing Surveys (CSUR) archive
Volume 17 ,  Issue 4  (December 1985) table of contents
The MIT Press scientific computation series
Pages: 471 - 523  
Year of Publication: 1985
ISSN:0360-0300
Authors
Luca Cardelli  AT&T Bell Laboratories, Murray Hill, NJ
Peter Wegner  Brown Univ., Providence, RI
Publisher
ACM  New York, NY, USA
Bibliometrics
Downloads (6 Weeks): 78,   Downloads (12 Months): 480,   Citation Count: 270
Additional Information:

abstract   references   cited by   index terms   review   collaborative colleagues  

Tools and Actions: Request Permissions Request Permissions    Review this Article  
DOI Bookmark: Use this link to bookmark this Article: http://doi.acm.org/10.1145/6041.6042
What is a DOI?

ABSTRACT

Our objective is to understand the notion of type in programming languages, present a model of typed, polymorphic programming languages that reflects recent research in type theory, and examine the relevance of recent research to the design of practical programming languages. Object-oriented languages provide both a framework and a motivation for exploring the interaction among the concepts of type, data abstraction, and polymorphism, since they extend the notion of type to data abstraction and since type inheritance is an important form of polymorphism. We develop a &lgr;-calculus-based model for type systems that allows us to explore these interactions in a simple setting, unencumbered by complexities of production programming languages. The evolution of languages from untyped universes to monomorphic and then polymorphic type systems is reviewed. Mechanisms for polymorphism such as overloading, coercion, subtyping, and parameterization are examined. A unifying framework for polymorphic type systems is developed in terms of the typed &lgr;-calculus augmented to include binding of types by quantification as well as binding of values by abstraction. The typed &lgr;-calculus is augmented by universal quantification to model generic functions with type parameters, existential quantification and packaging (information hiding) to model abstract data types, and bounded quantification to model subtypes and type inheritance. In this way we obtain a simple and precise characterization of a powerful type system that includes abstract data types, parametric polymorphism, and multiple inheritance in a single consistent framework. The mechanisms for type checking for the augmented &lgr;-calculus are discussed. The augmented typed &lgr;-calculus is used as a programming language for a variety of illustrative examples. We christen this language Fun because fun instead of &lgr; is the functional abstraction keyword and because it is pleasant to deal with. Fun is mathematically simple and can serve as a basis for the design and implementation of real programming languages with type facilities that are more powerful and expressive than those of existing programming languages. In particular, it provides a basis for the design of strongly typed object-oriented languages.


REFERENCES

Note: OCR errors may be found in this Reference List extracted from the full text article. ACM has opted to expose the complete List rather than only correct and linked references.

 
1
2
 
3
 
4
 
5
6
 
7
CARDELLI, L. 1984a. Basic polymorphic typechecking. Computing Science Tech. Rep. 119, AT&T Bell Laboratories, Murray Hill, N.J. Also in Polymorph. Newslett. 2, 1 (Jan.).
 
8
 
9
 
10
COQUAND, T., AND HUET, G. 1985. Constructions: a higher-order proof system for mechanizing mathematics. Tech. Rep. 401, INRIA, Rocquencourt, France (May).
 
11
CURRY, H. B., AND FEYS, R. 1958. Combinatory Logic. North-Holland Publ., Amsterdam.
 
12
DAMAS, L. 1984. Ph.D. dissertation. Dept. of Computer Science, Univ. of Edinburgh, Edinburgh, Scotland.
13
 
14
DEMERS, A., AND DONAHUE, J. 1979. Revised report on Russell. TR 79-389, Computer Science Dept., Cornell Univ., Ithaca, N.Y.
 
15
DOD (U.S. DEPARTMENT OF DEFENSE) 1983. Ada reference manual. ANSI/MIS-STD 1815 (Jan.). U.S. Govt. Printing Office.
 
16
FAIRBAIRN, J. 1982. Ponder and its type system. Tech. Rep. 31, Computer Laboratory, Univ. of Cambridge, Cambridge, England. (Nov.).
 
17
GIRARD, J.-Y. 1971. Une extension de l'interpretation de Godel ~ l'analyse, et son application a l'/~limination des coupures dans l'analyse et la th~orie des types. In Proceedings of the 2nd Scandinavian Logic Symposium, J. E. Fenstad, Ed. North-Holland Publ., Amsterdam, pp. 63- 92.
 
18
 
19
GOROON, M., MILNER, R., AND WADSWORTH, C. 1979. Edinburgh LCF. Lecture Notes in Computer Science, vol. 78. Springer-Verlag, New York.
 
20
HENDLER, J., AND WEGNER, P. 1986. Viewing object-oriented programming as an enhancement of data abstraction methodology. In Proceedings of the Hawaii Conference on System Sciences (Jan.).
 
21
HINOLEY, R. 1969. The principal type scheme of an object in combinatory logic. Trans. Am. Math. Soc. 146 (Dec.), 29-60.
 
22
 
23
24
25
26
 
27
MARTIN-LOF, P. 1980. Intuitionistic type theory. Notes of Giovanni Sambin on a series of lectures given in Padova, Univ. of Padova, Italy (June).
 
28
MATTHEWS, D. C. J. 1985. Poly manual. Tech. Rep. No. 63, Computer Laboratory, Univ. of Cambridge, Cambridge, England.
 
29
MILNER, R. 1978. A theory of type polymorphism in programming. J. Comput. Syst. Sci. 17, 348-375.
30
 
31
32
 
33
MITCHELL, J. C., MAYBURY, W., AND SWEET, R. 1979. Mesa language manual. Rep. CSL-79-3, Xerox Palo Alto Research Center, Palo Alto, Calif. (Apr.).
 
34
 
35
36
 
37
SCHMIOT, E. E. 1982. Controlling large software development in a distributed environment. Rep. CSL-82-7, Xerox Palo Alto Research Center, Palo Alto, Calif. (Dec.).
 
38
SCOTT, D. S. 1976. Data types as lattices. SIAM J. Comput. 5, 3, 523-587.
39
 
40
STRACHEY, C. 1967. Fundamental concepts in programming languages. Lecture notes for International Summer School in Computer Programming, Copenhagen, Aug.
41
 
42
WEINREB, D., AND MOON, D. 1981. LISP Machine Manual, Chapter 20: Objects, Message-Passing, and Flavors. Symbolics Inc., Cambridge, Mass.
 
43
WELSH, J., SNEERINGER, W. J., AND HOARE, C. A. R. 1977. Ambiguities and insecurities in Pascal. So{tw. Pract. Exper. (Nov.).
 
44

CITED BY  270


REVIEW

"Edward A. Schneider : Reviewer"

With the large amount of work done in the last few years on types, this paper is long overdue. The second-order typed &lgr;-calculus is used as a model for typed programs. The model is shown to be very flexible, permitting both parametric and in  more...

Collaborative Colleagues:
Luca Cardelli: colleagues
Peter Wegner: colleagues