| 3492 | } |
| 3493 | |
| 3494 | WASMEDGE_CAPI_EXPORT const WasmEdge_FunctionTypeContext * |
| 3495 | WasmEdge_VMGetFunctionType(const WasmEdge_VMContext *Cxt, |
| 3496 | const WasmEdge_String FuncName) noexcept { |
| 3497 | try { |
| 3498 | if (Cxt) { |
| 3499 | const auto FuncList = Cxt->VM.getFunctionList(); |
| 3500 | for (const auto &It : FuncList) { |
| 3501 | if (It.first == genStrView(FuncName)) { |
| 3502 | return toFuncTypeCxt(&It.second); |
| 3503 | } |
| 3504 | } |
| 3505 | } |
| 3506 | } catch (...) { |
| 3507 | handleCAPIError(); |
| 3508 | } |
| 3509 | return nullptr; |
| 3510 | } |
| 3511 | |
| 3512 | WASMEDGE_CAPI_EXPORT const WasmEdge_FunctionTypeContext * |
| 3513 | WasmEdge_VMGetFunctionTypeRegistered(const WasmEdge_VMContext *Cxt, |