diff options
Diffstat (limited to 'Userland/Libraries/LibJS/Bytecode/Pass/GenerateCFG.cpp')
-rw-r--r-- | Userland/Libraries/LibJS/Bytecode/Pass/GenerateCFG.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/Userland/Libraries/LibJS/Bytecode/Pass/GenerateCFG.cpp b/Userland/Libraries/LibJS/Bytecode/Pass/GenerateCFG.cpp index 476cc937b7..a3ec92ca5b 100644 --- a/Userland/Libraries/LibJS/Bytecode/Pass/GenerateCFG.cpp +++ b/Userland/Libraries/LibJS/Bytecode/Pass/GenerateCFG.cpp @@ -90,12 +90,15 @@ void GenerateCFG::perform(PassPipelineExecutable& executable) enter_label(&resume_target, current_block); continue; } - default: - // Otherwise, pop the current block off, it doesn't jump anywhere. + case Throw: + case Return: iterators.take_last(); entered_blocks.take_last(); continue; - } + default: + dbgln("Unhandled terminator instruction: `{}`", instruction.to_deprecated_string(executable.executable)); + VERIFY_NOT_REACHED(); + }; } finished(); |