Code review feedback.
* Move `Module::compile` to `Engine::precompile_module`. * Remove `Module::deserialize` method. * Make `Module::serialize` the same format as `Engine::precompile_module`. * Make `Engine::precompile_module` return a `Vec<u8>`. * Move the remaining serialization-related code to `serialization.rs`.
This commit is contained in:
@@ -31,7 +31,7 @@ fn deserialize(buffer: &[u8]) -> Result<()> {
|
||||
|
||||
// Compile the wasm binary into an in-memory instance of a `Module`.
|
||||
println!("Deserialize module...");
|
||||
let module = Module::deserialize(store.engine(), buffer)?;
|
||||
let module = Module::new(store.engine(), buffer)?;
|
||||
|
||||
// Here we handle the imports of the module, which in this case is our
|
||||
// `HelloCallback` type and its associated implementation of `Callback.
|
||||
|
||||
Reference in New Issue
Block a user