Utilities/wasm: Say something when execution traps
This commit is contained in:
parent
84e3957dc3
commit
d9ed3b504e
Notes:
sideshowbarker
2024-07-18 17:54:27 +09:00
Author: https://github.com/alimpfard Commit: https://github.com/SerenityOS/serenity/commit/d9ed3b504e4 Pull-request: https://github.com/SerenityOS/serenity/pull/7097 Reviewed-by: https://github.com/Dexesttp
1 changed files with 2 additions and 0 deletions
|
@ -131,6 +131,8 @@ int main(int argc, char* argv[])
|
|||
}
|
||||
|
||||
auto result = machine.invoke(run_address.value(), move(values));
|
||||
if (result.is_trap())
|
||||
warnln("Execution trapped!");
|
||||
if (!result.values().is_empty())
|
||||
warnln("Returned:");
|
||||
for (auto& value : result.values()) {
|
||||
|
|
Loading…
Add table
Reference in a new issue