diff --git a/c_bindings/pocketpy_c.cpp b/c_bindings/pocketpy_c.cpp index fd64ca6e..2e88fa11 100644 --- a/c_bindings/pocketpy_c.cpp +++ b/c_bindings/pocketpy_c.cpp @@ -167,7 +167,7 @@ PyObject* c_function_wrapper(VM* vm, ArgsView args) { CVM* cvm = (CVM*) vm; //setup c stack - ValueStackImpl local_stack = ValueStackImpl(); + ValueStackImpl local_stack; for (int i = 0; i < args.size(); i++) local_stack.push(args[i]); @@ -185,7 +185,7 @@ PyObject* c_function_wrapper(VM* vm, ArgsView args) { if (retc == 1) ret = local_stack.top(); else if (retc > 1) { - Tuple t = Tuple(retc); + Tuple t(retc); for (int i = 0; i < retc; i++) { int stack_index = (local_stack.size() - retc) + i; diff --git a/run_c_binding_test.sh b/run_c_binding_test.sh index b3078724..172e1660 100644 --- a/run_c_binding_test.sh +++ b/run_c_binding_test.sh @@ -22,4 +22,5 @@ echo "cleaning up" rm pocketpy_c.o rm test.o rm binding_test_scratch +rm c_binding_test