forked from bytecodealliance/wasm-tools
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
wast: Add exnref, try_table, and throw_ref
These types and instructions are part of the exception handling rework tracked in (WebAssembly/exception-handling#281).
- Loading branch information
Showing
15 changed files
with
208 additions
and
1 deletion.
There are no files selected for viewing
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
(module | ||
(func | ||
try | ||
unreachable | ||
catch_all | ||
rethrow 0 | ||
end | ||
(block | ||
) | ||
) | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
(module | ||
(func (param exnref)) | ||
(func (param (ref null exn))) | ||
(func (param (ref exn))) | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
(module | ||
(func (param exnref) | ||
local.get 0 | ||
throw_ref | ||
) | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
(module | ||
(tag $a (param i32)) | ||
|
||
(func | ||
try_table | ||
end | ||
|
||
try_table (result i32) | ||
i32.const 0 | ||
end | ||
drop | ||
|
||
try_table (catch $a 0) | ||
end | ||
|
||
try_table (catch $a 0) (catch $a 0) | ||
end | ||
|
||
try_table (catch_all 0) | ||
end | ||
|
||
try_table (catch $a 0) (catch_all 0) | ||
end | ||
|
||
try_table (catch $a 0) (catch $a 0) (catch_all 0) | ||
end | ||
|
||
try_table (result i32) (catch $a 0) | ||
i32.const 0 | ||
end | ||
drop | ||
|
||
try_table (result i32) (catch $a 0) (catch $a 0) | ||
i32.const 0 | ||
end | ||
drop | ||
|
||
try_table (result i32) (catch_all 0) | ||
i32.const 0 | ||
end | ||
drop | ||
|
||
try_table (result i32) (catch $a 0) (catch_all 0) | ||
i32.const 0 | ||
end | ||
drop | ||
|
||
try_table (result i32) (catch $a 0) (catch $a 0) (catch_all 0) | ||
i32.const 0 | ||
end | ||
drop | ||
) | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters