[fpc-pascal] Modern Compiler Construction using Pascal

Marc Santhoff M.Santhoff at web.de
Tue Jan 2 16:30:40 CET 2018

On Mon, 2018-01-01 at 13:17 -0500, Yves Cloutier wrote:
> Hi there,
> I'd be interested to know if any modern compilers have been written in
> Pascal (other than the Pascal Compiler).
> It's unfortunate that that most Pascal books out there are rather dated.  I
> did recently purchase
> mailman/listinfo/fpc-pascal

Pascal purists, please do not read on!


Really good an modern books on writing compilers are those from Terence
Parr. They are really readable and understandable, forget about the
Dragon Book.

The tool in use is the well known ANTLR, the newer versions implemented
in Java. If you want to build real compilers look for version 3, if
making DSLs is your target version 4 would be appropriate.

Have a look at antlr.org, the books to read are:

  "The Definitive ANTLR Reference - Building Domain Specific Languages"

Like the title says, a verbose and well written refernce for using

The best book on the topic by far is (for me):

  "Language Implementation Patterns"

That's a very clear, pragmatic, and analytic view on compiler
construction. It is structured modular and easy to read. Guido van
Rossum, the creator of Python, writes about it "Throw away your
compiler theory book!"
I would really appreciate a translation of the code from the book to
pascal. ;)


Sorry for mentioning something nasty like Java on this list.

Marc Santhoff <M.Santhoff at web.de>

More information about the fpc-pascal mailing list