The order is which things are covered is pretty standard for programming languages. Chapters 11 and 12 cover mutation. PLAI (https://www.plai.org/) covers similar material in a similar order.
The book is a theoretical and practical guide to understanding the principles of programming languages. Unlike books that teach a single language for application development, this one focuses on the semantics, syntax, and core concepts that are common across languages. It uses Scala as the main teaching language to build interpreters and type checkers, but its goal is not to teach Scala itself; rather, Scala is a tool to explore universal programming language principles.
The book covers key programming language features such as immutability, functions, pattern matching, recursion, mutation, garbage collection, lazy evaluation, continuations, type systems, algebraic data types, and polymorphism. It introduces these by first presenting them in simplified “toy” languages and then showing how to implement interpreters and type checkers for them. This approach ensures readers understand not just how to use language features, but why they work and what rules govern them across programming languages.
Its importance compared to other programming books lies in its generalization. Most beginner programming books teach one specific language (e.g., Python, Java, C++) and focus on syntax and usage. This book instead equips readers with the foundational concepts of programming languages so that they can more easily learn any new language in the future. By separating syntax (surface-level appearance) from semantics (underlying meaning), it teaches readers to recognize the deep commonalities among languages, making it a valuable resource for students, researchers, and advanced programmers aiming to go beyond coding into programming language theory and design.
Implementing a programming language is very easy when you have pattern matching and algebraic data types (which implies types). Python, JS, and C lack some or all of these. Scala is not special in this regard, though. Any modern language with FP ancestry will have these features.
So its good because of Scala's ability to implement a programming language and not Scala's language itself being good on its own for general abstract sudo like code. Or does Scala write cleanly (like people say Python does) and is also elegantly able to expands it's own simple syntax?
It bugs me how languages like JS are clean but any custom domain-specific language made in them is ugly.
For the authors of this book, I imagine it was a combination of Scala having the features they wanted, plus it being relatively popular, easy to install, and having good tooling.
I've written a lot of Scala in the last 15 years or so, and I really like the language. It has features that most programmers are not familiar with, which can scare off some. My opinion is that if you understand the features it is a very elegant and simple language, particularly Scala 3.
Should be called "Introduction to Functional Programming Languages"
The order is which things are covered is pretty standard for programming languages. Chapters 11 and 12 cover mutation. PLAI (https://www.plai.org/) covers similar material in a similar order.
https://www-users.york.ac.uk/~ss44/joke/foot.htm
I find the above the best introduction to a programming language.
Doesn't seem to cover any logic programming, that's a shame.
[The following is an AI generated description]
The book is a theoretical and practical guide to understanding the principles of programming languages. Unlike books that teach a single language for application development, this one focuses on the semantics, syntax, and core concepts that are common across languages. It uses Scala as the main teaching language to build interpreters and type checkers, but its goal is not to teach Scala itself; rather, Scala is a tool to explore universal programming language principles.
The book covers key programming language features such as immutability, functions, pattern matching, recursion, mutation, garbage collection, lazy evaluation, continuations, type systems, algebraic data types, and polymorphism. It introduces these by first presenting them in simplified “toy” languages and then showing how to implement interpreters and type checkers for them. This approach ensures readers understand not just how to use language features, but why they work and what rules govern them across programming languages.
Its importance compared to other programming books lies in its generalization. Most beginner programming books teach one specific language (e.g., Python, Java, C++) and focus on syntax and usage. This book instead equips readers with the foundational concepts of programming languages so that they can more easily learn any new language in the future. By separating syntax (surface-level appearance) from semantics (underlying meaning), it teaches readers to recognize the deep commonalities among languages, making it a valuable resource for students, researchers, and advanced programmers aiming to go beyond coding into programming language theory and design.
Is Scala actually special for doing this? Would Python equally work or JS / C wouldn't work because types?
Implementing a programming language is very easy when you have pattern matching and algebraic data types (which implies types). Python, JS, and C lack some or all of these. Scala is not special in this regard, though. Any modern language with FP ancestry will have these features.
So its good because of Scala's ability to implement a programming language and not Scala's language itself being good on its own for general abstract sudo like code. Or does Scala write cleanly (like people say Python does) and is also elegantly able to expands it's own simple syntax?
It bugs me how languages like JS are clean but any custom domain-specific language made in them is ugly.
For the authors of this book, I imagine it was a combination of Scala having the features they wanted, plus it being relatively popular, easy to install, and having good tooling.
I've written a lot of Scala in the last 15 years or so, and I really like the language. It has features that most programmers are not familiar with, which can scare off some. My opinion is that if you understand the features it is a very elegant and simple language, particularly Scala 3.
nah in fact scala will be one of the reasons very few people will read this book