Hacker News new | ask | show | jobs
by votr 3513 days ago
Is there support for only C/C++ at this time?
3 comments

There is pretty bleeding-edge support for compiling to both asm.js and WebAssembly in Rust that recently landed: https://users.rust-lang.org/t/compiling-to-the-web-with-rust...

So, at the very least there's support for C, C++, and Rust at the moment, though of course since the standards aren't yet finalized and the toolchains are evolving how well it works at any given moment may vary. I'm sure there's work going on for other languages to compile down to WASM, just not sure of the status of any other languages at the moment.

Rust can compile to wasm (and asm.js) as well via emscripten. More info here: https://users.rust-lang.org/t/compiling-to-the-web-with-rust...
Yes. WebAssembly like asm.js is intended for porting C/C++ apps to the web.

That said compiled languages should work if compilers add support for generating WebAssembly.

Yes, for instance Swift should be able to compile to web assembly? If Swift can be compiled with the clang/llvm toolchain, it should be able to target web assembly.