mirror of
https://github.com/SerenityOS/serenity.git
synced 2025-01-24 10:22:05 -05:00
LibJS/JIT: Clear exception before executing finalizer
language/statements/try/S12.14_A13_T2.js ❌ -> ✅ language/statements/try/S12.14_A15.js ❌ -> ✅ language/statements/try/S12.14_A7_T1.js ❌ -> ✅ language/statements/try/S12.14_A7_T2.js ❌ -> ✅ language/statements/try/S12.14_A7_T3.js ❌ -> ✅ language/statements/try/completion-values-fn-finally-abrupt.js ❌ -> ✅ language/statements/try/completion-values-fn-finally-return.js ❌ -> ✅
This commit is contained in:
parent
bd62c4763c
commit
0daebef727
1 changed files with 1 additions and 0 deletions
|
@ -398,6 +398,7 @@ void Compiler::check_exception()
|
|||
m_assembler.jump(label_for(*handler));
|
||||
no_exception.link(m_assembler);
|
||||
} else if (auto const* finalizer = current_block().finalizer(); finalizer) {
|
||||
store_vm_register(Bytecode::Register::exception(), GPR1);
|
||||
m_assembler.jump_if(Assembler::Operand::Register(GPR0),
|
||||
Assembler::Condition::NotEqualTo,
|
||||
Assembler::Operand::Register(GPR1),
|
||||
|
|
Loading…
Add table
Reference in a new issue