mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-22 15:40:19 +00:00
LibWasm: Remove a useless use of ScopeGuard
There are no multiple exit paths in that function, so we can just put the ending logic right at the end of the function instead.
This commit is contained in:
parent
65cd5526cb
commit
52a2518a69
Notes:
sideshowbarker
2024-07-18 08:54:41 +09:00
Author: https://github.com/alimpfard Commit: https://github.com/SerenityOS/serenity/commit/52a2518a69a
1 changed files with 8 additions and 10 deletions
|
@ -1126,17 +1126,15 @@ void DebuggerBytecodeInterpreter::interpret(Configuration& configuration, Instru
|
|||
}
|
||||
}
|
||||
|
||||
ScopeGuard guard { [&] {
|
||||
if (post_interpret_hook) {
|
||||
auto result = post_interpret_hook(configuration, ip, instruction, *this);
|
||||
if (!result) {
|
||||
m_trap = Trap { "Trapped by user request" };
|
||||
return;
|
||||
}
|
||||
}
|
||||
} };
|
||||
|
||||
BytecodeInterpreter::interpret(configuration, ip, instruction);
|
||||
|
||||
if (post_interpret_hook) {
|
||||
auto result = post_interpret_hook(configuration, ip, instruction, *this);
|
||||
if (!result) {
|
||||
m_trap = Trap { "Trapped by user request" };
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue