REVIEW - Language Implementation Patterns - Create Your Own Domain-specific and General Programming Languages


Title:

Language Implementation Patterns

Create Your Own Domain-specific and General Programming Languages

Author:

Terence Parr

Publisher:

Pragmatic Bookshelf (2010)

Pages:

374pp

Reviewer:

Paul Floyd

Reviewed:

July 2019

Rating:

★★★☆☆


This was my summer holiday reading. I should perhaps have taken a slightly longer book, but I wanted to keep the weight down.

The author of this book is also the creator of ANTLR (Another Tool for Language Recognition, something that I’d always imagined be some sort of backronym from LR, but no, ANTLR is LL – LR and LL being parser types). Parr clearly knows his stuff, and does a good job of explaining the processes. The explanations are clear and well laid out. The sample code is mostly in Java, but it is simple enough that anyone with a grounding in C or C++ should be able to follow it.

The chapters are mostly split into two parts. First is an overall introduction to the theory being covered. This then leads to ‘Patterns’, which cover the specifics and example implementations in more details. Often design choices are presented along with their advantages and disadvantages. The book progresses from basic parsing to template-driven generators in a steady fashion. Perhaps this comes from the study of grammars, but the explanations all seemed to progress without there ever being a need to refer to matter covered later in the book.

I only have a fairly small amount of experience with parsers and lexers (mainly with flex and bison), so the parts that were the most interesting to me were the extras that such old-school tools don’t offer (that I know of) like data models and rule rewriting.

Finally, I enjoyed this book so much that on return from my holidays I bought The Definitive ANTLR 4 Reference by the same author (watch this space, but don’t hold your breath).

Recommended.


Book cover image courtesy of Open Library.





Your Privacy

By clicking "Accept Non-Essential Cookies" you agree ACCU can store non-essential cookies on your device and disclose information in accordance with our Privacy Policy and Cookie Policy.

Current Setting: Non-Essential Cookies REJECTED


By clicking "Include Third Party Content" you agree ACCU can forward your IP address to third-party sites (such as YouTube) to enhance the information presented on this site, and that third-party sites may store cookies on your device.

Current Setting: Third Party Content EXCLUDED



Settings can be changed at any time from the Cookie Policy page.