few comments.
This commit is contained in:
committed by
Dan Gohman
parent
263fa098a1
commit
ee26b9ead7
@@ -110,7 +110,8 @@ impl Instance {
|
||||
let export = mutable.lookup(name).expect("export");
|
||||
if let wasmtime_runtime::Export::Function { signature, .. } = &export {
|
||||
// HACK ensure all handles, instantiated outside Store, present in
|
||||
// the store's SignatureRegistry.
|
||||
// the store's SignatureRegistry, e.g. WASI instances that are
|
||||
// imported into this store using the from_handle() method.
|
||||
use crate::runtime::SignatureRegistry;
|
||||
let _ = store.borrow_mut().register_cranelift_signature(signature);
|
||||
}
|
||||
|
||||
@@ -79,6 +79,9 @@ impl Engine {
|
||||
|
||||
// Store
|
||||
|
||||
/// The SignatureRegistry allow register new cranelift signature,
|
||||
/// and also quickly retrive the signature back using registration
|
||||
/// index.
|
||||
pub(crate) trait SignatureRegistry {
|
||||
fn register_cranelift_signature(
|
||||
&mut self,
|
||||
|
||||
Reference in New Issue
Block a user