MCPcopy Create free account
hub / github.com/bytecodealliance/wasmtime / post_return_impl

Method post_return_impl

crates/wasmtime/src/runtime/component/func.rs:550–565  ·  view source on GitHub ↗
(&self, mut store: impl AsContextMut, arg: ValRaw)

Source from the content-addressed store, hash-verified

548 }
549
550 pub(crate) fn post_return_impl(&self, mut store: impl AsContextMut, arg: ValRaw) -> Result<()> {
551 let mut store = store.as_context_mut();
552
553 let index = self.index;
554 let vminstance = self.instance.id().get(store.0);
555 let component = vminstance.component();
556 let (_ty, _def, options) = component.export_lifted_function(index);
557 let post_return = self.post_return_core_func(store.0);
558 let flags = vminstance.instance_flags(component.env_component().options[options].instance);
559
560 unsafe {
561 call_post_return(&mut store, post_return, arg, flags)?;
562 store.0.exit_guest_sync_call()?;
563 }
564 Ok(())
565 }
566
567 pub(crate) fn lower_args<T>(
568 cx: &mut LowerContext<'_, T>,

Callers 2

call_implMethod · 0.80
call_implMethod · 0.80

Calls 11

call_post_returnFunction · 0.85
OkFunction · 0.85
post_return_core_funcMethod · 0.80
env_componentMethod · 0.80
as_context_mutMethod · 0.45
getMethod · 0.45
idMethod · 0.45
componentMethod · 0.45
instance_flagsMethod · 0.45
exit_guest_sync_callMethod · 0.45

Tested by

no test coverage detected