This is a Token based full fledged interpreter that was meant to be a compilator for modula2. It ended up being a custom language interpreter with basic arithmetic, boolean logic and variable assignments.
Based on a standard tokenize -> parse -> process using production rules to understand and feed the tokens to the interpreter.
While my implementation is mostly original, a good part of the idea came from a site/book online, I can't remember the author, but it was a magnificent explanation of how code compilation worked and how to build a small scale compilator. I stopped at the first chapters, but what followed may help someone else
Thanks unknown author!