macro_rules! imports {
( $( $ns_name:expr => $ns:tt ),* $(,)? ) => { ... };
}
Expand description
Generate an ImportObject
easily with the imports!
macro.
Usage
use wasmer::imports;
let import_object = imports! {
"env" => {
"foo" => Function::new_native(&store, foo)
},
};
fn foo(n: i32) -> i32 {
n
}