| 97 | } |
| 98 | |
| 99 | own wasm_ref_t* call_i_r(const wasm_func_t* func, int32_t i) { |
| 100 | printf("call_i_r... "); fflush(stdout); |
| 101 | wasm_val_t vs[1] = { WASM_I32_VAL(i) }; |
| 102 | wasm_val_t rs[1] = { WASM_INIT_VAL }; |
| 103 | wasm_val_vec_t args = WASM_ARRAY_VEC(vs); |
| 104 | wasm_val_vec_t results = WASM_ARRAY_VEC(rs); |
| 105 | if (wasm_func_call(func, &args, &results)) { |
| 106 | printf("> Error calling function!\n"); |
| 107 | exit(1); |
| 108 | } |
| 109 | printf("okay\n"); |
| 110 | return rs[0].of.ref; |
| 111 | } |
| 112 | |
| 113 | void check(own wasm_ref_t* actual, const wasm_ref_t* expected) { |
| 114 | if (actual != expected && |
no test coverage detected