-
Notifications
You must be signed in to change notification settings - Fork 714
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add binary format parse checking for ref.as input type (#4389)
If that type is not valid then we cannot even create and finalize the node, which means we'd hit an assertion inside finalize(), before we reach the validator. Fixes #4383
- Loading branch information
Showing
3 changed files
with
9 additions
and
0 deletions.
There are no files selected for viewing
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,6 @@ | ||
;; Test that we error properly on a file with a ref.as of a non-ref type. | ||
|
||
;; RUN: not wasm-opt %s.wasm 2>&1 | filecheck %s | ||
|
||
;; CHECK: parse exception: bad input type for ref.as: i32 | ||
|
Binary file not shown.