From 6941e76b7aedf084f0fc853595ef8ffb1adeadc2 Mon Sep 17 00:00:00 2001 From: Alistair Date: Fri, 27 Oct 2023 15:30:20 +0100 Subject: [PATCH] Remove panic converting `NoInstructonsRemaining` to `OpaqeError` --- boa_engine/src/error.rs | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/boa_engine/src/error.rs b/boa_engine/src/error.rs index 6749a8b6f2b..01fc8be6c73 100644 --- a/boa_engine/src/error.rs +++ b/boa_engine/src/error.rs @@ -940,9 +940,7 @@ impl JsNativeError { JsNativeErrorKind::Uri => (constructors.uri_error().prototype(), ErrorKind::Uri), #[cfg(feature = "fuzz")] JsNativeErrorKind::NoInstructionsRemain => { - unreachable!( - "The NoInstructionsRemain native error cannot be converted to an opaque type." - ) + (constructors.eval_error().prototype(), ErrorKind::Eval) } JsNativeErrorKind::RuntimeLimit => { panic!("The RuntimeLimit native error cannot be converted to an opaque type.")