Computing Reviews
Today's Issue Hot Topics Search Browse Recommended My Account Log In
Review Help
Search
Programming language design and implementation: texts in computer science
Mogensen T., Springer, New York, NY, 2022. 323 pp. Type: Book (978-3031118050)
Date Reviewed: May 31 2024

Most books on the construction of compilers and interpreters consider either the fundamental mathematics that underpin them or the practice of implementing them. This book is different. It provides a refreshing discussion on the actual design of a programming language that the compiler or interpreter would implement. For example, in a language that you design: Should a user function pass parameters by name, value, reference, or a combination of these? Should you allow function nesting? How should functions be declared in the first place? Topics such as these form the cornerstone of each chapter apart from the first, with that chapter covering a distinct concept in the design and implementation of a programming language.

Mogensen’s book is principally aimed at readers who have some familiarity with basic compiler implementation techniques. It could quite easily be used as a textbook for an introductory graduate course in computer science as it has some pedagogic aids: a plethora of examples and further reading lists at the end of each chapter together with a set of exercises. However, including answers to the exercises (or a selection of them) would have helped self-study readers.

The first chapter provides a brief history of programming languages that unfortunately does not include modern languages such as Python, JavaScript, TypeScript, Rust, or Golang. Indeed, many of the examples given when considering design choices throughout the book are centered on older languages such as ALGOL and COBOL, which most readers today would have very little familiarity with.

The rest of the book can be considered to cover three main domains: strategic aspects, the elements (for example, control structures, functions, memory management) of a programming language, and considerations related to the paradigms encapsulated in a language. The first domain comprises chapters 2 and 3, where implementation strategies (for example, should your language be interpreted or compiled, bootstrapping the compilation) are considered. The second domain, consisting of chapters 4 to 8, forms the kernel of the book by discussing elements of the programming language such as the following concepts:

  • Memory management;
  • Scoping;
  • Functions and parameter passing;
  • Control structures; and
  • Modularization.

Chapters 9 to 12, forming the third logical domain, discuss the various types (for example, embedded languages, logic languages, object-oriented languages) and paradigms related to programming languages such as domain specificity and semantics.

Aho, Ullman, and Sethi’s compiler book, fondly called the “dragon book” [1], as well as the earlier seminal “green dragon book” [2], still remain the classic texts on compilers, although in some ways a lot has changed in the field of compiler technology since they were published. (Incidentally, both of the authors of the “green dragon book” won the 2020 Turing Award for their work on compilers.) Other books, notably Engineering a compiler [3] and Modern compiler implementation in C [4], are well-regarded texts that provide a practical approach to compiler construction. However, these books do not consider the design of a programming language in any detail and so Mogensen complements them appropriately.

In conclusion, this book complements the variety of books on compiler design and implementation by considering design choices related to a programming language, and thereby enhances its compiler’s implementation. It does this by illustrating concepts using examples related to various programming languages. In effect, the book is a welcome addition to the world of compiler construction and is bound to remain a fixture in the compiler implementer’s repertoire for some time.

Reviewer:  Nayan Ruparelia Review #: CR147773
1) Aho, A. V.; Lam, M. S.; Sethi, R.; Ullman, J. D. Compilers: principles, techniques, and tools (2nd ed.). Addison-Wesley, Boston, MA, 2007.
2) Aho, A. V.; Ullman, J. D. Principles of compiler design. Addison-Wesley, Reading, MA, 1977.
3) Cooper, K. D.; Torczon, L. Engineering a compiler (2nd ed.). Morgan Kaufmann Publishers, Burlington, MA, 2012.
4) Appel, A. W.; Ginsburg, M. Modern compiler implementation in C. Cambridge University Press, New York, NY, 1998.
Bookmark and Share
 
General (D.3.0 )
 
 
Formal Definitions And Theory (D.3.1 )
 
 
General (C.5.0 )
 
 
Language Constructs and Features (D.3.3 )
 
Would you recommend this review?
yes
no
Other reviews under "General": Date
Programming languages: paradigm and practice
Appleby D., McGraw-Hill, Inc., New York, NY, 1991. Type: Book (9780075579045)
Jan 1 1992
Programming languages
Dershem H. (ed), Jipping M., Wadsworth Publ. Co., Belmont, CA, 1990. Type: Book (9780534129002)
Jan 1 1992
Comparative programming languages
Friedman L., Prentice-Hall, Inc., Upper Saddle River, NJ, 1991. Type: Book (9780131554825)
Jan 1 1992
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