From bea5569cd34b43267a0ac44293cf4eb288fc0c3f Mon Sep 17 00:00:00 2001 From: "Tobin C. Harding" Date: Fri, 24 Jun 2022 09:54:22 +1000 Subject: [PATCH] Remove duplicate must_use Clippy emits: warning: this function has an empty `#[must_use]` attribute, but returns a type already marked as `#[must_use]` This is because the return type of the function `legacy_encode_signing_data_to` is `EncodeSigningDataResult` which is already marked as `must_use`. There is no need to have `must_use` on the function also. I'm guessing this got through to master because we only just added clippy to CI. --- src/util/sighash.rs | 1 - 1 file changed, 1 deletion(-) diff --git a/src/util/sighash.rs b/src/util/sighash.rs index 2af83ad9..a3b6abce 100644 --- a/src/util/sighash.rs +++ b/src/util/sighash.rs @@ -647,7 +647,6 @@ impl> SighashCache { /// Encodes the legacy signing data for any flag type into a given object implementing a /// [`std::io::Write`] trait. Internally calls [`Transaction::encode_signing_data_to`]. - #[must_use] pub fn legacy_encode_signing_data_to>( &self, mut writer: Write,