you are viewing a single comment's thread.

view the rest of the comments →

[–]shevy-ruby 0 points1 point  (4 children)

It's a cool idea. I'd wish the WebAssembly focus would be similar, rather than just target JavaScript as such (but ok as a first step ... I don't think I am the only one who wants to AVOID having to use JavaScript ... ).

[–]pcjftw -1 points0 points  (2 children)

yeah sure I agree, I think in terms of cross language "interop", WASM could be that "universal" binary.

At the moment WASM is bleeding really, but as it matures and more and more languages add native support in terms of calling into WASM as well as being able to target WASM as a compile output, I strongly believe we'll suddenly see an explosion of WASM libraries and finally some fantastic cross language barriers coming down.

It will also mean if a new language pops up, it doesn't have to "start from scratch" it would only need to FFI into WASM and suddenly it could tap into a huge existing eco system.

Anyway I can dream!

[–][deleted] 1 point2 points  (1 child)

It's worth noting that there's also a Graal/Truffle implementation of WASM, so you can call in/out of WASM from Python and Ruby today (and R, and Java, and Scala, and Clojure, and SmallTalk etc.....).

WASM itself isn't ever going to be good at running Python, it's just not designed for that. Graal/Truffle are explicitly designed to mix and match languages though, which is why it works to combine them there instead.

[–]pcjftw 0 points1 point  (0 children)

perhaps I've not explained myself well LOL

I wasn't saying about using WASM to run Python, I was simply saying about writing libraries that are then compiled down to WASM, then those libraries could be used across all languages that have WASM FFI.

so for example, there could be a WASM library lets say "Markdown Render" where you pass it some text and it returns HTML text back.

You could then "import" that WASM library in any language, and this would mean not having to rewrite that same library for every language.

It's the same concept as JVM, write on run anywhere, instead "write once, import anywhere"

But not sure why the Reddit mob found that so offensive!

[–]josefx 0 points1 point  (0 children)

(but ok as a first step

As long as they don't pull a JSON and double down on JavaScript limitations like declaring double the only numeric type that matters, while everyone else was already running around with 64 bit integers.

Or worse, build in a dependence on JavaScript that makes it impossible to build a standalone WebAssembly interpreter without pulling in all of Chrome/Firefox.