Building a Toy Programming Language in Python, Part 2
Posted by
on underWelcome to the second part of my tutorial on creating a toy language I called my
in Python. In the first part I showed how how to implement the lexer, parser and interpreter for a very simple version of the language that did only one thing: print numbers.
With the first phase of the project completed, and with a solid base to start building from, I'll show you how to extend the language in a few ways. The purpose of this is to demonstrate how to modify this language, so that you can then build your own extensions. If you need a reference for the code, this GitHub repository has the working code that you can try.