Scrap Virtual Machine and begin again

I just didn't like the style of it.
This commit is contained in:
Ginger Bill
2016-11-03 16:26:22 +00:00
parent 8534e064b9
commit 6c2772d093
7 changed files with 1358 additions and 1194 deletions

View File

@@ -166,15 +166,13 @@ int main(int argc, char **argv) {
ssa_gen_tree(&ssa);
#if 1
{
VirtualMachine vm = {};
vm_init(&vm, &ssa.module);
defer (vm_destroy(&vm));
#if 0
VirtualMachine vm = {};
vm_init(&vm, &ssa.module);
// defer (vm_destroy(&vm));
Array<vmValue> args = {}; // Empty
vm_call_proc_by_name(&vm, make_string("main"), args);
}
Array<vmValue> main_args = {}; // Empty
vm_call_proc_by_name(&vm, make_string("main"), main_args);
#endif
{