This post is part of the Stack Based Virtual Machines series. In the previous part we have written the ANTLR grammar for an assembler for our virtual machine. In this part, we’ll write the code connected to the ANTLR-generated parser to actually make our assembler work! The code for this part is on GitHub. Main Let’s start - for once! - with the main function and not with an unit test.| andreabergia.com
This post is part of the Stack Based Virtual Machines series. In the previous part we have implemented an “if” and a “while” statement. In this part, we’ll extend our virtual machine and add support for function calls! The status of the code at the time of this article can be seen on GitHub. Calling a function A function is generally nothing more than a particular address that the code jumps to.| andreabergia.com