mirror of
https://github.com/rustwasm/wasm-bindgen.git
synced 2024-11-28 05:52:21 +03:00
68537b9649
This commit adds an optimization to `wasm-bindgen` to directly import and invoke other modules' functions from the wasm module, rather than going through a shim in the imported bindings. This will be an important optimization in the future for the host bindings proposal, but for now it's largely just a proof-of-concept to show that we can do it and is unlikely to bring about many performance benefits. The implementation in this commit is largely refactoring to reorganize a bit how functions are imported, but the implementation happens in `generate_import_function`. With this commit, 71/287 imports in the `tests/wasm/main.rs` suite get hooked up directly to the ES modules, no shims needed! |
||
---|---|---|
.. | ||
crates | ||
no-std | ||
wasm | ||
headless.rs | ||
non_wasm.rs | ||
std-crate-no-std-dep.rs |