Toy_VM and Toy_Stack are working and tested, read more

At this point, only a minimal number of operations are working, and
after running any kind of source code, the 'result' is simply left on
the VM's stack. Still, it's awesome to see it reach this point.
This commit is contained in:
2024-09-27 15:12:37 +10:00
parent 0504f4af8b
commit c518960171
11 changed files with 573 additions and 84 deletions

View File

@@ -86,7 +86,7 @@ int test_bytecode_from_source(Toy_Bucket* bucket) {
}
//check contents of the routine (this is copy/pasted from test_routine.c, and tweaked with the offset)
int offset = strlen(TOY_VERSION_BUILD) + 3;
int offset = 3 + strlen(TOY_VERSION_BUILD) + 1;
if (offset % 4 != 0) {
offset += 4 - (offset % 4); //ceil
}