The Definitive Antlr 4 Reference

Published Nov. 15, 2012 by Pragmatic Bookshelf.

ISBN:
978-1-934356-99-9
Copied ISBN!

View on OpenLibrary

5 stars (1 review)

1 edition

Review of 'The Definitive Antlr 4 Reference' on 'Goodreads'

5 stars

What an emotional rollercoaster!

I went from being a true believer in a language-agnostic event-based parsing in order to keep the code out of the grammar to maximize reuse... to a true believer in the impossibility of keeping code out of the grammar, since it inevitably needs to ask for higher level context from some other module or have embedded predicates in order to parse some things correctly and efficiently... within a few week span.

It feels like a fairly good solution to the leaky abstraction of separate lexer, parser, and app components, but there are a ton of unexplained ramifications to this stuff, and to rewriting Left-recursive phrases. It leaves me with a pseudo-religious dread, as if I discovered an ancient stone room behind a wall while remodeling a basement.

Most of the book explores trivial examples not actually compliant with any language spec. I wish we could have …