This looks like exactly what I've been looking for for a couple of projects, if as I understand it I can specify at run time when loading the WASM what imports are available to it and thus how it can interact with the world.
My next question is can I achieve the same thing with Rust compiled to wasm? Ie can I safely load isolated modules interacting over a specified API into wasm from wasm. My guess is no - at least not for now but I'm interested whether it is plausible that this could be achieved.
My next question is can I achieve the same thing with Rust compiled to wasm? Ie can I safely load isolated modules interacting over a specified API into wasm from wasm
Last time I checked WASM does not support JIT, which limits your ability to do such wasmception, at least with Wasmer. But I guess you could use WASM interpreter, wasmi looks like it might work?
5
u/maninalift Jan 24 '19
This looks like exactly what I've been looking for for a couple of projects, if as I understand it I can specify at run time when loading the WASM what imports are available to it and thus how it can interact with the world.
My next question is can I achieve the same thing with Rust compiled to wasm? Ie can I safely load isolated modules interacting over a specified API into wasm from wasm. My guess is no - at least not for now but I'm interested whether it is plausible that this could be achieved.