From 33f89279e7fcc85a098aa4b4c5ecd094cd269d41 Mon Sep 17 00:00:00 2001 From: Roman Date: Tue, 26 Nov 2024 08:37:11 -0300 Subject: [PATCH] Make Signature::new a const fn (#810) --- crates/primitives/src/signature/sig.rs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/crates/primitives/src/signature/sig.rs b/crates/primitives/src/signature/sig.rs index f121c4730..537b155c6 100644 --- a/crates/primitives/src/signature/sig.rs +++ b/crates/primitives/src/signature/sig.rs @@ -114,8 +114,7 @@ impl Signature { } /// Instantiate a new signature from `r`, `s`, and `v` values. - #[allow(clippy::missing_const_for_fn)] - pub fn new(r: U256, s: U256, v: Parity) -> Self { + pub const fn new(r: U256, s: U256, v: Parity) -> Self { Self { r, s, v } }