mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 15:38:10 +00:00
LibJS: Move the current exception from Interpreter to VM
This will allow us to throw exceptions even when there is no active interpreter in the VM.
This commit is contained in:
parent
675b482fe7
commit
4a8bfcdd1c
12 changed files with 26 additions and 23 deletions
|
@ -48,7 +48,7 @@ void EventDispatcher::dispatch(EventTarget& target, NonnullRefPtr<Event> event)
|
|||
auto& interpreter = target.script_execution_context()->interpreter();
|
||||
(void)interpreter.call(function, this_value, Bindings::wrap(global_object, target));
|
||||
if (interpreter.exception())
|
||||
interpreter.clear_exception();
|
||||
interpreter.vm().clear_exception();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue