From d1368d041eb42d265a4ef385e066b82bc36d0743 Mon Sep 17 00:00:00 2001 From: Tom French <15848336+TomAFrench@users.noreply.github.com> Date: Wed, 21 Jun 2023 21:13:02 +0700 Subject: [PATCH] chore!: remove unused `OpcodeResolutionError::IncorrectNumFunctionArguments` variant (#397) --- acvm/src/pwg/blackbox/ecdsa.rs | 1 + acvm/src/pwg/mod.rs | 2 -- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/acvm/src/pwg/blackbox/ecdsa.rs b/acvm/src/pwg/blackbox/ecdsa.rs index 59bae409f..8bad9cd9a 100644 --- a/acvm/src/pwg/blackbox/ecdsa.rs +++ b/acvm/src/pwg/blackbox/ecdsa.rs @@ -45,6 +45,7 @@ pub(super) fn secp256k1_prehashed( ) -> Result { let hashed_message = to_u8_vec(initial_witness, hashed_message_inputs)?; + // These errors should never be emitted in practice as they would imply malformed ACIR generation. let pub_key_x: [u8; 32] = to_u8_vec(initial_witness, public_key_x_inputs)?.try_into().map_err(|_| { OpcodeResolutionError::BlackBoxFunctionFailed( diff --git a/acvm/src/pwg/mod.rs b/acvm/src/pwg/mod.rs index cf3a9f281..16951c232 100644 --- a/acvm/src/pwg/mod.rs +++ b/acvm/src/pwg/mod.rs @@ -78,8 +78,6 @@ pub enum OpcodeResolutionError { UnsupportedBlackBoxFunc(BlackBoxFunc), #[error("could not satisfy all constraints")] UnsatisfiedConstrain, - #[error("expected {0} inputs for function {1}, but got {2}")] - IncorrectNumFunctionArguments(usize, BlackBoxFunc, usize), #[error("failed to solve blackbox function: {0}, reason: {1}")] BlackBoxFunctionFailed(BlackBoxFunc, String), #[error("failed to solve brillig function, reason: {0}")]