{ "source_filename": "tests/testsuite/proposals/wasm-3.0/br_on_cast_fail.wast", "commands": [ { "type": "module", "line": 3, "filename": "br_on_cast_fail.0.wasm", "module_type": "binary" }, { "type": "action", "line": 69, "action": { "type": "invoke", "field": "init", "args": [ { "type": "externref", "value": "0" } ] } }, { "type": "assert_return", "line": 71, "action": { "type": "invoke", "field": "br_on_non_null", "args": [ { "type": "i32", "value": "0" } ] }, "expected": [ { "type": "i32", "value": "0" } ] }, { "type": "assert_return", "line": 72, "action": { "type": "invoke", "field": "br_on_non_null", "args": [ { "type": "i32", "value": "1" } ] }, "expected": [ { "type": "i32", "value": "-1" } ] }, { "type": "assert_return", "line": 73, "action": { "type": "invoke", "field": "br_on_non_null", "args": [ { "type": "i32", "value": "2" } ] }, "expected": [ { "type": "i32", "value": "-1" } ] }, { "type": "assert_return", "line": 74, "action": { "type": "invoke", "field": "br_on_non_null", "args": [ { "type": "i32", "value": "3" } ] }, "expected": [ { "type": "i32", "value": "-1" } ] }, { "type": "assert_return", "line": 75, "action": { "type": "invoke", "field": "br_on_non_null", "args": [ { "type": "i32", "value": "4" } ] }, "expected": [ { "type": "i32", "value": "-1" } ] }, { "type": "assert_return", "line": 77, "action": { "type": "invoke", "field": "br_on_non_i31", "args": [ { "type": "i32", "value": "0" } ] }, "expected": [ { "type": "i32", "value": "-1" } ] }, { "type": "assert_return", "line": 78, "action": { "type": "invoke", "field": "br_on_non_i31", "args": [ { "type": "i32", "value": "1" } ] }, "expected": [ { "type": "i32", "value": "7" } ] }, { "type": "assert_return", "line": 79, "action": { "type": "invoke", "field": "br_on_non_i31", "args": [ { "type": "i32", "value": "2" } ] }, "expected": [ { "type": "i32", "value": "-1" } ] }, { "type": "assert_return", "line": 80, "action": { "type": "invoke", "field": "br_on_non_i31", "args": [ { "type": "i32", "value": "3" } ] }, "expected": [ { "type": "i32", "value": "-1" } ] }, { "type": "assert_return", "line": 81, "action": { "type": "invoke", "field": "br_on_non_i31", "args": [ { "type": "i32", "value": "4" } ] }, "expected": [ { "type": "i32", "value": "-1" } ] }, { "type": "assert_return", "line": 83, "action": { "type": "invoke", "field": "br_on_non_struct", "args": [ { "type": "i32", "value": "0" } ] }, "expected": [ { "type": "i32", "value": "-1" } ] }, { "type": "assert_return", "line": 84, "action": { "type": "invoke", "field": "br_on_non_struct", "args": [ { "type": "i32", "value": "1" } ] }, "expected": [ { "type": "i32", "value": "-1" } ] }, { "type": "assert_return", "line": 85, "action": { "type": "invoke", "field": "br_on_non_struct", "args": [ { "type": "i32", "value": "2" } ] }, "expected": [ { "type": "i32", "value": "6" } ] }, { "type": "assert_return", "line": 86, "action": { "type": "invoke", "field": "br_on_non_struct", "args": [ { "type": "i32", "value": "3" } ] }, "expected": [ { "type": "i32", "value": "-1" } ] }, { "type": "assert_return", "line": 87, "action": { "type": "invoke", "field": "br_on_non_struct", "args": [ { "type": "i32", "value": "4" } ] }, "expected": [ { "type": "i32", "value": "-1" } ] }, { "type": "assert_return", "line": 89, "action": { "type": "invoke", "field": "br_on_non_array", "args": [ { "type": "i32", "value": "0" } ] }, "expected": [ { "type": "i32", "value": "-1" } ] }, { "type": "assert_return", "line": 90, "action": { "type": "invoke", "field": "br_on_non_array", "args": [ { "type": "i32", "value": "1" } ] }, "expected": [ { "type": "i32", "value": "-1" } ] }, { "type": "assert_return", "line": 91, "action": { "type": "invoke", "field": "br_on_non_array", "args": [ { "type": "i32", "value": "2" } ] }, "expected": [ { "type": "i32", "value": "-1" } ] }, { "type": "assert_return", "line": 92, "action": { "type": "invoke", "field": "br_on_non_array", "args": [ { "type": "i32", "value": "3" } ] }, "expected": [ { "type": "i32", "value": "3" } ] }, { "type": "assert_return", "line": 93, "action": { "type": "invoke", "field": "br_on_non_array", "args": [ { "type": "i32", "value": "4" } ] }, "expected": [ { "type": "i32", "value": "-1" } ] }, { "type": "assert_return", "line": 95, "action": { "type": "invoke", "field": "null-diff", "args": [ { "type": "i32", "value": "0" } ] }, "expected": [ { "type": "i32", "value": "1" } ] }, { "type": "assert_return", "line": 96, "action": { "type": "invoke", "field": "null-diff", "args": [ { "type": "i32", "value": "1" } ] }, "expected": [ { "type": "i32", "value": "0" } ] }, { "type": "assert_return", "line": 97, "action": { "type": "invoke", "field": "null-diff", "args": [ { "type": "i32", "value": "2" } ] }, "expected": [ { "type": "i32", "value": "1" } ] }, { "type": "assert_return", "line": 98, "action": { "type": "invoke", "field": "null-diff", "args": [ { "type": "i32", "value": "3" } ] }, "expected": [ { "type": "i32", "value": "0" } ] }, { "type": "assert_return", "line": 99, "action": { "type": "invoke", "field": "null-diff", "args": [ { "type": "i32", "value": "4" } ] }, "expected": [ { "type": "i32", "value": "0" } ] }, { "type": "module", "line": 104, "filename": "br_on_cast_fail.1.wasm", "module_type": "binary" }, { "type": "action", "line": 220, "action": { "type": "invoke", "field": "test-sub", "args": [] } }, { "type": "action", "line": 221, "action": { "type": "invoke", "field": "test-canon", "args": [] } }, { "type": "module", "line": 226, "filename": "br_on_cast_fail.2.wasm", "module_type": "binary" }, { "type": "assert_invalid", "line": 241, "filename": "br_on_cast_fail.3.wasm", "module_type": "binary", "text": "type mismatch" }, { "type": "assert_invalid", "line": 250, "filename": "br_on_cast_fail.4.wasm", "module_type": "binary", "text": "type mismatch" }, { "type": "assert_invalid", "line": 259, "filename": "br_on_cast_fail.5.wasm", "module_type": "binary", "text": "type mismatch" }, { "type": "assert_invalid", "line": 268, "filename": "br_on_cast_fail.6.wasm", "module_type": "binary", "text": "type mismatch" }, { "type": "assert_invalid", "line": 276, "filename": "br_on_cast_fail.7.wasm", "module_type": "binary", "text": "type mismatch" }, { "type": "assert_invalid", "line": 287, "filename": "br_on_cast_fail.8.wasm", "module_type": "binary", "text": "type mismatch" } ] }