pannous opened issue #4144:
How to get the arity of a wasmtime function in the c api?
int nresults = wasm_func_result_arity(wasmFunc);
works for wasm_func_t but doesn't work for wasmtime_func_t (EXC_BAD_ACCESS)
bjorn3 commented on issue #4144:
It doesn't look like there is a function for that in the wasmtime c api. That wasm_func_result_arity doesn't work for wasmtime_func_t is expected as you are mixing two different api's in that case. You need to use either the wasm_* api's or the wasmtime_* api's, you can't use both at the same time.
alexcrichton commented on issue #4144:
For this you'll need to use
wasmtime_func_type
followed bywasm_functype_results
which you can get the size from.
alexcrichton closed issue #4144:
How to get the arity of a wasmtime function in the c api?
int nresults = wasm_func_result_arity(wasmFunc);
works for wasm_func_t but doesn't work for wasmtime_func_t (EXC_BAD_ACCESS)
pannous commented on issue #4144:
that worked, thanks a lot!
Last updated: Dec 23 2024 at 12:05 UTC