Skip to content

Commit ddf5631

Browse files
authored
[Binary format] Encode continuation type index as an s33 (WebAssembly#89)
There is a small inconsistency between the reference implementation in WebAssembly#84 and the explainer. In the explainer we write that the type index `$ft` on `cont $ft` should be encoded as an `u32` in the binary format. However, the reference interpreter actually encodes it as `s33`, similarly to how concrete heap types are encoded.
1 parent b86490c commit ddf5631

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

proposals/stack-switching/Explainer.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -842,7 +842,7 @@ We extend the binary format of composite types, heap types, and instructions.
842842
| Opcode | Type | Parameters | Note |
843843
| ------ | --------------- | ---------- |------|
844844
| -0x20 | `func t1* t2*` | `t1* : vec(valtype)` `t2* : vec(valtype)` | from Wasm 1.0 |
845-
| -0x23 | `cont $ft` | `$ft : typeidx` | new |
845+
| -0x23 | `cont $ft` | `$ft : s33` | new |
846846

847847
#### Heap Types
848848

0 commit comments

Comments
 (0)