wasmerio / vscode-wasm

WebAssembly extension for VSCode
https://marketplace.visualstudio.com/items?itemName=dtsvet.vscode-wasm
MIT License
129 stars 19 forks source link

support `wasm-decompile` ? #24

Open aardappel opened 4 years ago

aardappel commented 4 years ago

wasm-decompile works almost identically to wasm2wat (and is also part of WABT) so presumably could be an alternative option in this plugin.

Details: https://github.com/WebAssembly/wabt/blob/master/docs/decompiler.md

@RReverser

syrusakbary commented 4 years ago

We would love to support it!

Right now we are using the wabt.js project maintained by @dcodeIO: https://github.com/AssemblyScript/wabt.js Wabt.js is using the Emscripten integration from wabt ( https://github.com/WebAssembly/wabt/blob/master/src/wabt.post.js ) but wabbt.post.js doesn't seem to support it yet.

There are a few ways we could integrate wasm-decompile:

  1. Update wabt wabt.post.js and update the wabt.js project
  2. Make wabt compatible with WASI. Note: there is an open PR that was aiming for that
  3. Other way?