官术网_书友最值得收藏!

Wasm

Wasm, which WebAssembly is now commonly called, is a binary format meant to complement JavaScript that Rust can be compiled to. The format is designed to run as a stack machine inside several sandboxed execution environments (such as web browsers, or the Node.js runtime) for performance-critical applications (https://blog.x5ff.xyz/blog/azure-functions-wasm-rust/). While this is—as of this writing—in its early stages, Rust and the Wasm target have been used in real-time frontend settings (such as browser games), and in 2018 there was a dedicated working group seeking to improve this integration.

Similar to other targets, such as ARM, the Wasm target is an LLVM (the compiler technology Rust is built on) backend so it has to be installed using rustup target add wasm32-unknown-unknown. Furthermore, it isn't necessary to declare the binary layout (the "C" in extern "C") and a different bindgen tool does the rest: wasm-bindgen, available at https://github.com/rustwasm/wasm-bindgen. We highly recommend reading the documentation for more information.

主站蜘蛛池模板: 鄂伦春自治旗| 道孚县| 房产| 鲁山县| 大埔区| 左云县| 襄汾县| 邯郸市| 合水县| 洞口县| 淮安市| 长治县| 三门峡市| 额尔古纳市| 定兴县| 夹江县| 将乐县| 双峰县| 高雄市| 铅山县| 晴隆县| 六安市| 策勒县| 舟山市| 黔江区| 岐山县| 广平县| 宝坻区| 济阳县| 漳浦县| 塔城市| 辽宁省| 江都市| 宜丰县| 长沙县| 阳春市| 富顺县| 泸州市| 东明县| 龙南县| 依安县|