Reset the API stack after a foreign constructor returns.

This commit is contained in:
Bob Nystrom
2016-08-28 08:23:27 -07:00
parent d331cbf43d
commit e7cabbb5e4
6 changed files with 82 additions and 1 deletions
+1
View File
@@ -659,6 +659,7 @@ static void createForeign(WrenVM* vm, ObjFiber* fiber, Value* stack)
method->fn.foreign(vm);
vm->apiStack = NULL;
// TODO: Check that allocateForeign was called.
}