{ "source_filename": "tests/testsuite/proposals/wasm-3.0/memory_trap0.wast", "commands": [ { "type": "module", "line": 1, "filename": "memory_trap0.0.wasm", "module_type": "binary" }, { "type": "assert_return", "line": 23, "action": { "type": "invoke", "field": "store", "args": [ { "type": "i32", "value": "-4" }, { "type": "i32", "value": "42" } ] }, "expected": [] }, { "type": "assert_return", "line": 24, "action": { "type": "invoke", "field": "load", "args": [ { "type": "i32", "value": "-4" } ] }, "expected": [ { "type": "i32", "value": "42" } ] }, { "type": "assert_trap", "line": 25, "action": { "type": "invoke", "field": "store", "args": [ { "type": "i32", "value": "-3" }, { "type": "i32", "value": "305419896" } ] }, "text": "out of bounds memory access" }, { "type": "assert_trap", "line": 26, "action": { "type": "invoke", "field": "load", "args": [ { "type": "i32", "value": "-3" } ] }, "text": "out of bounds memory access" }, { "type": "assert_trap", "line": 27, "action": { "type": "invoke", "field": "store", "args": [ { "type": "i32", "value": "-2" }, { "type": "i32", "value": "13" } ] }, "text": "out of bounds memory access" }, { "type": "assert_trap", "line": 28, "action": { "type": "invoke", "field": "load", "args": [ { "type": "i32", "value": "-2" } ] }, "text": "out of bounds memory access" }, { "type": "assert_trap", "line": 29, "action": { "type": "invoke", "field": "store", "args": [ { "type": "i32", "value": "-1" }, { "type": "i32", "value": "13" } ] }, "text": "out of bounds memory access" }, { "type": "assert_trap", "line": 30, "action": { "type": "invoke", "field": "load", "args": [ { "type": "i32", "value": "-1" } ] }, "text": "out of bounds memory access" }, { "type": "assert_trap", "line": 31, "action": { "type": "invoke", "field": "store", "args": [ { "type": "i32", "value": "0" }, { "type": "i32", "value": "13" } ] }, "text": "out of bounds memory access" }, { "type": "assert_trap", "line": 32, "action": { "type": "invoke", "field": "load", "args": [ { "type": "i32", "value": "0" } ] }, "text": "out of bounds memory access" }, { "type": "assert_trap", "line": 33, "action": { "type": "invoke", "field": "store", "args": [ { "type": "i32", "value": "-2147483648" }, { "type": "i32", "value": "13" } ] }, "text": "out of bounds memory access" }, { "type": "assert_trap", "line": 34, "action": { "type": "invoke", "field": "load", "args": [ { "type": "i32", "value": "-2147483648" } ] }, "text": "out of bounds memory access" }, { "type": "assert_return", "line": 35, "action": { "type": "invoke", "field": "memory.grow", "args": [ { "type": "i32", "value": "65537" } ] }, "expected": [ { "type": "i32", "value": "-1" } ] } ] }