wasmerio / wasmer

🚀 The leading Wasm Runtime supporting WASIX, WASI and Emscripten
https://wasmer.io
MIT License
18.44k stars 789 forks source link

Add support for Haskell #4399

Closed ad-si closed 1 month ago

ad-si commented 8 months ago

The latest versions of GHC include experimental support to compile to WebAssembly: https://ghc.gitlab.haskell.org/ghc/doc/users_guide/wasm.html

linear[bot] commented 8 months ago

RUN-44 Add support for Haskell

syrusakbary commented 7 months ago

I believe Haskell now compiles to Wasm32-wasi so it should be possible to run the generated files directly with Wasmer (without any modification).

We'll keep this issue open until we test that the generated wasm32-wasi file work properly

syrusakbary commented 7 months ago

@ad-si do you mean running Wasm inside of Haskell? Or running haskell compiled to wasm with Wasmer?

The solution you posted is mainly for the latter, but it may be useful to have the former as well (running Wasm inside of Haskell via Wasmer). If that's the case please let us know on this thread

ad-si commented 7 months ago

I actually meant running Wasm inside of Haskell (referring to the table in the readme: https://github.com/wasmerio/wasmer#wasmer-sdk). I just realized that compiling Haskell to Wasm is of course irrelevant for that 😅 But still interesting to know whether generated wasm32-wasi file work!

So maybe let's keep this issue for executing Haskell compiled to Wasm and open a new one for running Wasm inside of Haskell?