diff options
Diffstat (limited to 'Libraries/LibJS/AST.cpp')
-rw-r--r-- | Libraries/LibJS/AST.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/Libraries/LibJS/AST.cpp b/Libraries/LibJS/AST.cpp index 098d4699dd..6bf047859a 100644 --- a/Libraries/LibJS/AST.cpp +++ b/Libraries/LibJS/AST.cpp @@ -1899,7 +1899,8 @@ Value SwitchStatement::execute(Interpreter& interpreter, GlobalObject& global_ob return {}; if (interpreter.vm().should_unwind()) { if (interpreter.vm().should_unwind_until(ScopeType::Continuable, m_label)) { - ASSERT_NOT_REACHED(); + // No stop_unwind(), the outer loop will handle that - we just need to break out of the switch/case. + return {}; } else if (interpreter.vm().should_unwind_until(ScopeType::Breakable, m_label)) { interpreter.vm().stop_unwind(); return {}; |