Principles of Programming Languages



Book Details
Authors | Mike Grant, Zachary Palmer, Scott Smith |
Published | 2020 |
Edition | 1 |
Paperback | 163 pages |
Language | English |
License | Creative Commons Attribution-ShareAlike |
Book Description
In this open book, the authors aim to study the fundamental concepts in programming languages, rather than teaching a range of specific languages. They posit that while languages are easy to learn, the concepts behind them are difficult. The basic features they examine in turn include higher-order functions, data structures in the form of records and variants, mutable state, exceptions, objects and classes, and types. The book also covers language implementations, both through interpreters and compilers. Throughout the text, the authors guide the reader in writing small interpreters for toy languages, and in Chapter 8, they present the construction of a principled compiler. They define type checkers to identify which programs are well-typed and which are not. A more precise, mathematical view of interpreters and type checkers is also adopted, through the concepts of operational semantics and type systems, concepts that have historically evolved from the logician's view of programming.
The material has evolved from lecture notes used in a programming languages course for juniors, seniors, and graduate students at Johns Hopkins University. Although the book employs formal mathematical techniques like operational semantics and type systems, it does not emphasize proofs of properties of these systems. The authors nonetheless sketch the intuitions behind some proofs.
This book is available under a Creative Commons Attribution-ShareAlike license (CC BY-SA), which means that you are free to copy, distribute, and modify it, as long as you credit the original author and license any derivative works under the same terms.
If you enjoyed the book and would like to support the author, you can purchase a printed copy (hardcover or paperback) from official retailers.