4 ms·
I think another contender here would be OCaml/Reason, which has both JavaScript and WebAsm targeting, is used in systems space (eg Mirage). Its a bit different
by justincormack 9y ago
I think another contender here would be OCaml/Reason, which has both JavaScript and WebAsm targeting, is used in systems space (eg Mirage). Its a bit different in technical choices (functional, GC, for example). Facebook is using Reason for Messenger for example, on mobile.
- d215 9y agoHonest question, Is reason really targeting wasm right now? Do you know a resource describing this? I cannot find anything about this.
- bad_user 9y agoAFAIK Reason is a frontend for OCaml and can target whatever OCaml can target. Note that for targeting JavaScript they are using BuckleScript, an OCaml backend that's not built by Facebook.
- rlp 9y agoI couldn't find anything on this either. The assembly emitters in their repo don't suggest a WASM backend: https://github.com/ocaml/ocaml/tree/trunk/asmcomp https://github.com/ocaml/ocaml/tree/trunk/asmcomp
- k__ 9y agohttps://github.com/sebmarkbage/ocamlrun-wasm https://github.com/sebmarkbage/ocamlrun-wasm reason == ocaml
- stewbrew 9y agoYes, but a byte code interpreter ported to wasm via emscripten != a compiler with a WASM backend.
- k__ 9y agoIsn't the stuff that comes out of the OCaml compiler byte code? As far as I can tell, OCaml has a GC and WASM (at the moment) doesn't so this seems like the only viable solution to me.
- colanderman 9y agoOCaml also has a native x86 backend, which produces quite efficient code.
- idibidiart 9y agoAny links to instructions for Reason WASM targeting?
- k__ 9y agohttps://github.com/sebmarkbage/ocamlrun-wasm https://github.com/sebmarkbage/ocamlrun-wasm
- smt88 9y agoI consider Rust to be functional, although people would dispute that, I'm sure. GC is a huge difference though.
- yen223 9y agoRust doesn't have great support for function composition or partial application, both of which I think are essential to be considered a "functional" language. Others will have different opinions for sure, and that's fine.
- shams93 9y agoThere is a project TrueBit is working on for ocaml and wasm integration.