WebAssembly / WebAssembly/wabt

wat2wasm demo seems a little outdated

Open
#2,711 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C++
Stars
8.1k
Forks
827
Avg merge
4d 6h
Merged PRs (30d)
18

Description

https://webassembly.github.io/wabt/demo/wat2wasm/ errors on the following code even with exceptions checked on:

(module
  (tag $e0)
  (func (export "simple-throw-catch") (param i32) (result i32)
    (block $h
      (try_table (result i32) (catch $e0 $h)
        (if (i32.eqz (local.get 0)) (then (throw $e0)) (else))
        (i32.const 42)
      )
      (return)
    )
    (i32.const 23)
  )
)

but the downloaded wat2wasm with --enable-exceptions handles this fine.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the provided WAT example in the web demo with exceptions enabled, then compare its behavior with the downloaded wat2wasm using --enable-exceptions. Trace why the demo rejects code that the command-line tool accepts; done means the demo accepts this example consistently with wat2wasm.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp, wasm
Domain
devtools
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
50/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.