Lazy and Interpreter Design

I think, I’d better visit some kind of tutorial to get the knowledge about interpreter implementation. I searched the Internet and found one. Link: https://craftinginterpreters.com/introduction.html.

This one is actually an online book. Skimming through the first few parts takes me back to the college. I searched ‘recursive descent parser’ on Google, to take a quick look back. Back to the book, it brings back many terms from the college, as well as introducing some more ideas. There are 2 phases here, lexical analysis, which would give us tokens, with unnecessary stuff cleaned out. The next phase is parser generation, which would give us the parser to parse the language. There are many things. to visit, like, symbol table, etc. The book has a complete design for 2 interpreters, one done in Java and one done in C.

Leave a Reply

Discover more from Amol's Code Blog

Subscribe now to keep reading and get access to the full archive.

Continue reading