Skip to content

Commit

Permalink
Merge pull request #424 from WebAssembly/test-br-on-cast-types
Browse files Browse the repository at this point in the history
Test that br_on_cast{_fail} must do a down cast
  • Loading branch information
rossberg authored Sep 12, 2023
2 parents 5d2313b + c27610d commit 5d31ec1
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
8 changes: 8 additions & 0 deletions test/core/gc/br_on_cast.wast
Original file line number Diff line number Diff line change
Expand Up @@ -249,3 +249,11 @@
)
"type mismatch"
)
(assert_invalid
(module
(func (result anyref)
(br_on_cast 0 eqref anyref (unreachable))
)
)
"type mismatch"
)
8 changes: 8 additions & 0 deletions test/core/gc/br_on_cast_fail.wast
Original file line number Diff line number Diff line change
Expand Up @@ -264,3 +264,11 @@
)
"type mismatch"
)
(assert_invalid
(module
(func (result anyref)
(br_on_cast_fail 0 eqref anyref (unreachable))
)
)
"type mismatch"
)

0 comments on commit 5d31ec1

Please sign in to comment.