{ "source_filename": "tests/cli/legacy-exceptions/try_catch.wast", "commands": [ { "type": "module", "line": 5, "filename": "try_catch.0.wasm", "module_type": "binary" }, { "type": "register", "line": 10, "as": "test" }, { "type": "module", "line": 12, "filename": "try_catch.1.wasm", "module_type": "binary" }, { "type": "assert_return", "line": 215, "action": { "type": "invoke", "field": "empty-catch", "args": [] }, "expected": [] }, { "type": "assert_return", "line": 217, "action": { "type": "invoke", "field": "simple-throw-catch", "args": [ { "type": "i32", "value": "0" } ] }, "expected": [ { "type": "i32", "value": "23" } ] }, { "type": "assert_return", "line": 218, "action": { "type": "invoke", "field": "simple-throw-catch", "args": [ { "type": "i32", "value": "1" } ] }, "expected": [ { "type": "i32", "value": "42" } ] }, { "type": "assert_trap", "line": 220, "action": { "type": "invoke", "field": "unreachable-not-caught", "args": [] }, "text": "unreachable" }, { "type": "assert_return", "line": 222, "action": { "type": "invoke", "field": "trap-in-callee", "args": [ { "type": "i32", "value": "7" }, { "type": "i32", "value": "2" } ] }, "expected": [ { "type": "i32", "value": "3" } ] }, { "type": "assert_trap", "line": 223, "action": { "type": "invoke", "field": "trap-in-callee", "args": [ { "type": "i32", "value": "1" }, { "type": "i32", "value": "0" } ] }, "text": "integer divide by zero" }, { "type": "assert_return", "line": 225, "action": { "type": "invoke", "field": "catch-complex-1", "args": [ { "type": "i32", "value": "0" } ] }, "expected": [ { "type": "i32", "value": "3" } ] }, { "type": "assert_return", "line": 226, "action": { "type": "invoke", "field": "catch-complex-1", "args": [ { "type": "i32", "value": "1" } ] }, "expected": [ { "type": "i32", "value": "4" } ] }, { "type": "assert_exception", "line": 227, "action": { "type": "invoke", "field": "catch-complex-1", "args": [ { "type": "i32", "value": "2" } ] } }, { "type": "assert_return", "line": 229, "action": { "type": "invoke", "field": "catch-complex-2", "args": [ { "type": "i32", "value": "0" } ] }, "expected": [ { "type": "i32", "value": "3" } ] }, { "type": "assert_return", "line": 230, "action": { "type": "invoke", "field": "catch-complex-2", "args": [ { "type": "i32", "value": "1" } ] }, "expected": [ { "type": "i32", "value": "4" } ] }, { "type": "assert_exception", "line": 231, "action": { "type": "invoke", "field": "catch-complex-2", "args": [ { "type": "i32", "value": "2" } ] } }, { "type": "assert_return", "line": 233, "action": { "type": "invoke", "field": "throw-catch-param-i32", "args": [ { "type": "i32", "value": "0" } ] }, "expected": [ { "type": "i32", "value": "0" } ] }, { "type": "assert_return", "line": 234, "action": { "type": "invoke", "field": "throw-catch-param-i32", "args": [ { "type": "i32", "value": "1" } ] }, "expected": [ { "type": "i32", "value": "1" } ] }, { "type": "assert_return", "line": 235, "action": { "type": "invoke", "field": "throw-catch-param-i32", "args": [ { "type": "i32", "value": "10" } ] }, "expected": [ { "type": "i32", "value": "10" } ] }, { "type": "assert_return", "line": 237, "action": { "type": "invoke", "field": "throw-catch-param-f32", "args": [ { "type": "f32", "value": "1084227584" } ] }, "expected": [ { "type": "f32", "value": "1084227584" } ] }, { "type": "assert_return", "line": 238, "action": { "type": "invoke", "field": "throw-catch-param-f32", "args": [ { "type": "f32", "value": "1093140480" } ] }, "expected": [ { "type": "f32", "value": "1093140480" } ] }, { "type": "assert_return", "line": 240, "action": { "type": "invoke", "field": "throw-catch-param-i64", "args": [ { "type": "i64", "value": "5" } ] }, "expected": [ { "type": "i64", "value": "5" } ] }, { "type": "assert_return", "line": 241, "action": { "type": "invoke", "field": "throw-catch-param-i64", "args": [ { "type": "i64", "value": "0" } ] }, "expected": [ { "type": "i64", "value": "0" } ] }, { "type": "assert_return", "line": 242, "action": { "type": "invoke", "field": "throw-catch-param-i64", "args": [ { "type": "i64", "value": "-1" } ] }, "expected": [ { "type": "i64", "value": "-1" } ] }, { "type": "assert_return", "line": 244, "action": { "type": "invoke", "field": "throw-catch-param-f64", "args": [ { "type": "f64", "value": "4617315517961601024" } ] }, "expected": [ { "type": "f64", "value": "4617315517961601024" } ] }, { "type": "assert_return", "line": 245, "action": { "type": "invoke", "field": "throw-catch-param-f64", "args": [ { "type": "f64", "value": "4622100592565682176" } ] }, "expected": [ { "type": "f64", "value": "4622100592565682176" } ] }, { "type": "assert_return", "line": 247, "action": { "type": "invoke", "field": "catch-param-i32", "args": [ { "type": "i32", "value": "5" } ] }, "expected": [ { "type": "i32", "value": "5" } ] }, { "type": "assert_return", "line": 249, "action": { "type": "invoke", "field": "catch-imported", "args": [] }, "expected": [ { "type": "i32", "value": "2" } ] }, { "type": "assert_return", "line": 251, "action": { "type": "invoke", "field": "catchless-try", "args": [ { "type": "i32", "value": "0" } ] }, "expected": [ { "type": "i32", "value": "0" } ] }, { "type": "assert_return", "line": 252, "action": { "type": "invoke", "field": "catchless-try", "args": [ { "type": "i32", "value": "1" } ] }, "expected": [ { "type": "i32", "value": "1" } ] }, { "type": "assert_exception", "line": 254, "action": { "type": "invoke", "field": "return-call-in-try-catch", "args": [] } }, { "type": "assert_exception", "line": 255, "action": { "type": "invoke", "field": "return-call-indirect-in-try-catch", "args": [] } }, { "type": "assert_return", "line": 257, "action": { "type": "invoke", "field": "break-try-catch", "args": [] }, "expected": [] }, { "type": "assert_return", "line": 258, "action": { "type": "invoke", "field": "break-try-catch_all", "args": [] }, "expected": [] }, { "type": "module", "line": 260, "filename": "try_catch.2.wasm", "module_type": "binary" }, { "type": "assert_return", "line": 278, "action": { "type": "invoke", "field": "imported-mismatch", "args": [] }, "expected": [ { "type": "i32", "value": "3" } ] }, { "type": "assert_invalid", "line": 299, "filename": "try_catch.3.wasm", "module_type": "binary", "text": "type mismatch" }, { "type": "assert_invalid", "line": 301, "filename": "try_catch.4.wasm", "module_type": "binary", "text": "type mismatch" }, { "type": "assert_invalid", "line": 303, "filename": "try_catch.5.wasm", "module_type": "binary", "text": "type mismatch" }, { "type": "assert_invalid", "line": 305, "filename": "try_catch.6.wasm", "module_type": "binary", "text": "type mismatch" }, { "type": "assert_invalid", "line": 310, "filename": "try_catch.7.wasm", "module_type": "binary", "text": "type mismatch" } ] }