diff options
author | Sam Clegg <sbc@chromium.org> | 2022-03-02 17:07:36 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-03-02 17:07:36 -0800 |
commit | e385ff4b792aa5497471d80f863e7436fc6a110a (patch) | |
tree | d0d699011a359fe29d07920e914e221fec8d001f /test/spec/table_size.txt | |
parent | 1dea1ee053cd9de4345ada0cf0b197066f92968b (diff) | |
download | wabt-e385ff4b792aa5497471d80f863e7436fc6a110a.tar.gz wabt-e385ff4b792aa5497471d80f863e7436fc6a110a.tar.bz2 wabt-e385ff4b792aa5497471d80f863e7436fc6a110a.zip |
Fix function body start/end locations in wasm-validate (#1842)
For text validation, this means the error is always correctly reported on
the final expression in the function.
For binary validation, this means that we report the byte after the last
instruction in the function as the failure location. This is in line
with other binary validation reports. For example, for `type mismatch
in i32.add` we report the validation error at the byte *after* the add
instruction.
Diffstat (limited to 'test/spec/table_size.txt')
-rw-r--r-- | test/spec/table_size.txt | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/test/spec/table_size.txt b/test/spec/table_size.txt index c6b13ff1..906356c0 100644 --- a/test/spec/table_size.txt +++ b/test/spec/table_size.txt @@ -2,10 +2,10 @@ ;;; STDIN_FILE: third_party/testsuite/table_size.wast (;; STDOUT ;;; out/test/spec/table_size.wast:70: assert_invalid passed: - out/test/spec/table_size/table_size.1.wasm:0000020: error: type mismatch at end of function, expected [] but got [i32] + out/test/spec/table_size/table_size.1.wasm:0000021: error: type mismatch at end of function, expected [] but got [i32] 0000021: error: EndFunctionBody callback failed out/test/spec/table_size.wast:79: assert_invalid passed: - out/test/spec/table_size/table_size.2.wasm:0000021: error: type mismatch in implicit return, expected [f32] but got [i32] + out/test/spec/table_size/table_size.2.wasm:0000022: error: type mismatch in implicit return, expected [f32] but got [i32] 0000022: error: EndFunctionBody callback failed 38/38 tests passed. ;;; STDOUT ;;) |