Enable multi-module support for wasm-c-api (#426)

it is allowed that all imported functions and globals can be
linked by multi-module feature automatically or by wasm-c-api manually
This commit is contained in:
lum1n0us
2020-10-16 17:43:57 +08:00
committed by GitHub
parent f1fe5d7872
commit 4787b150b8
26 changed files with 550 additions and 185 deletions

View File

@ -1362,12 +1362,8 @@ label_pop_csp_n:
/* always call module own functions */
cur_func = module->functions + fidx;
if (cur_func->is_import_func
#if WASM_ENABLE_MULTI_MODULE != 0
&& !cur_func->import_func_inst
#endif
)
cur_func_type = cur_func->u.func_import->func_type;
if (cur_func->is_import_func)
cur_func_type = cur_func->u.func_import->func_type;
else
cur_func_type = cur_func->u.func->func_type;
if (!wasm_type_equal(cur_type, cur_func_type)) {