Update wasmtime to 0.29.0 (#9552)

* Start

* Move to ctx

* Make it compile for now

* More work

* Get rid off state-holder

* Use less Refcells

* 🤦

* Don't use RefCell

* Use names for parameters

* Fixes after merge

* Fixes after merge

* Review feedback

* FMT
This commit is contained in:
Bastian Köcher
2021-09-29 14:30:46 +02:00
committed by GitHub
parent e64693933f
commit 2deed49706
19 changed files with 451 additions and 430 deletions
@@ -78,21 +78,21 @@ pub trait WasmInstance: Send {
/// Before execution, instance is reset.
///
/// Returns the encoded result on success.
fn call(&self, method: InvokeMethod, data: &[u8]) -> Result<Vec<u8>, Error>;
fn call(&mut self, method: InvokeMethod, data: &[u8]) -> Result<Vec<u8>, Error>;
/// Call an exported method on this WASM instance.
///
/// Before execution, instance is reset.
///
/// Returns the encoded result on success.
fn call_export(&self, method: &str, data: &[u8]) -> Result<Vec<u8>, Error> {
fn call_export(&mut self, method: &str, data: &[u8]) -> Result<Vec<u8>, Error> {
self.call(method.into(), data)
}
/// Get the value from a global with the given `name`.
///
/// This method is only suitable for getting immutable globals.
fn get_global_const(&self, name: &str) -> Result<Option<Value>, Error>;
fn get_global_const(&mut self, name: &str) -> Result<Option<Value>, Error>;
/// **Testing Only**. This function returns the base address of the linear memory.
///