3 ms·
WebAssembly modules can import from other modules: https://github.com/WebAssembly/design/blob/master/Modules.md#imports https://github.com/WebAssembly/design/b
by comex 9y ago
WebAssembly modules can import from other modules:
https://github.com/WebAssembly/design/blob/master/Modules.md#imports https://github.com/WebAssembly/design/blob/master/Modules.md...
By itself that’s the equivalent of dynamic linking; I don’t know if anyone’s written a static linker yet, but it’s an obvious next step.
However, just like with native code, there will be problems with different languages having different representations of strings, arrays, etc., and C and its sparse type system being the least common denominator.
- kodablah 9y ago> I don’t know if anyone’s written a static linker yet, but it’s an obvious next step. Essentially just wasm-merge [0]. > However, just like with native code, there will be problems with different languages having different representations of strings, arrays, etc., This is the biggest hurtle. Someone needs to provide a WASM interface for backends to implement and frontends to target that provides a minimal stdlib. Until then, it's libc and posix by way of emscripten. 0 - https://github.com/WebAssembly/binaryen/pull/919 https://github.com/WebAssembly/binaryen/pull/919