Computing Reviews
Today's Issue Hot Topics Search Browse Recommended My Account Log In
Review Help
Search
Types and programming languages
Pierce B., MIT Press, Cambridge, MA, 2002. 645 pp. Type: Book (9780262162098)
Date Reviewed: Jan 24 2003

Pierce defines a type system as “a tractable syntactic method for proving the absence of certain program behaviors by classifying phrases according to the types of values they compute.” Don’t let this formal definition lead you into believing that the significance of type systems is only theoretical. A type system is one of the most important aspects of a programming language’s design. It provides the foundation for the compiler, and sometimes the runtime system, to detect many programmer errors, thus avoiding unspecified behavior such as program crashes. Many of the security breaches we commonly see on the Internet are nothing more than type violations that are not properly detected. Programmers who switch to a strongly typed language often express their surprise when their programs “just work” without additional debugging.

This book guides us through the rich and interesting field of type system design, reasoning, and implementation. Using operational semantics, and examples written in Objective Caml (OCaml), available on the book’s associated Web site, Pierce navigates through an eclectic and wide selection of theoretical topics with clarity and consistency. Modern typography is wisely employed throughout the book to clearly express complicated lambda reduction sequences, operational semantics, and programming examples. Numerous exercises, of varying degrees of difficulty, and detailed references make the book useful to the mature undergraduate or graduate student and the researcher alike.

Pierce presents language features following a common pattern, going through motivating examples, formal definitions, proofs of basic properties, presentation of type checking algorithms and proofs of their soundness, completeness, and termination, and algorithm implementation. The topics covered include the formal representation of untyped arithmetic expressions using lambda calculus, simple types, subtyping, recursive types, polymorphism, and higher-order types. Although emphasis is placed on the type systems of functional languages such as Haskell and meta language (ML), relationships with mainstream languages such as Java and C++ are discussed as the related theory develops. Missing from the book is a survey chapter presenting the particular characteristics, advantages, and shortcomings of the type systems of widespread modern languages. Such a chapter would have placed the theory in a more practical setting, helping both students of programming languages and budding language designers. One must not be ungrateful however; the book succeeds in bringing together, between one set of covers, the most significant elements of a difficult but important computer science field.

Reviewer:  D. Spinellis Review #: CR126884 (0304-0325)
Bookmark and Share
  Featured Reviewer  
 
Type Structure (F.3.3 ... )
 
 
Applicative (Functional) Languages (D.3.2 ... )
 
 
Formal Languages (F.4.3 )
 
 
Language Constructs and Features (D.3.3 )
 
 
Mathematical Logic (F.4.1 )
 
Would you recommend this review?
yes
no
Other reviews under "Type Structure": Date
Equational type logic
Manca V., Salibra A., Scollo G. (ed) Theoretical Computer Science 77(1-2): 131-159, 1990. Type: Article
Dec 1 1991
Data types over multiple-valued logics
Pigozzi D. Theoretical Computer Science 77(1-2): 161-194, 1990. Type: Article
Aug 1 1992
An algebraically specified language for data directed design
Wagner E. Theoretical Computer Science 77(1-2): 195-219, 1990. Type: Article
Jul 1 1991
more...

E-Mail This Printer-Friendly
Send Your Comments
Contact Us
Reproduction in whole or in part without permission is prohibited.   Copyright 1999-2024 ThinkLoud®
Terms of Use
| Privacy Policy