From 6f64e39dda3a4f2e356ba08508ae73c77907cd92 Mon Sep 17 00:00:00 2001 From: Volker Mische Date: Mon, 27 Feb 2023 16:10:56 +0100 Subject: [PATCH] Fix function call on component instance (#5887) The exported function in the instance is not called directly by its name, but by `call_`. --- crates/wasmtime/src/component/mod.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/wasmtime/src/component/mod.rs b/crates/wasmtime/src/component/mod.rs index 15212fb928..e5cc6d4969 100644 --- a/crates/wasmtime/src/component/mod.rs +++ b/crates/wasmtime/src/component/mod.rs @@ -135,7 +135,7 @@ pub(crate) use self::store::ComponentStoreData; /// /// // Here our `greet` function doesn't take any parameters for the component, /// // but in the Wasmtime embedding API the first argument is always a `Store`. -/// bindings.greet(&mut store)?; +/// bindings.call_greet(&mut store)?; /// Ok(()) /// } /// ```