Add ability for debugger to throw errors.

This commit is contained in:
Stephen Chung
2022-01-25 21:31:35 +08:00
parent b4f679d35f
commit 3c2ac7f0c5
8 changed files with 78 additions and 50 deletions

View File

@@ -196,7 +196,7 @@ impl Engine {
) -> RhaiResult {
#[cfg(feature = "debugging")]
let reset_debugger =
self.run_debugger_with_reset(scope, global, state, lib, this_ptr, stmt, level);
self.run_debugger_with_reset(scope, global, state, lib, this_ptr, stmt, level)?;
// Coded this way for better branch prediction.
// Popular branches are lifted out of the `match` statement into their own branches.