diff --git a/primitives/src/script/borrowed.rs b/primitives/src/script/borrowed.rs index c7269e33d..8e0ea3f5a 100644 --- a/primitives/src/script/borrowed.rs +++ b/primitives/src/script/borrowed.rs @@ -92,7 +92,7 @@ impl Script { /// Returns the script data as a byte slice. /// /// This is just the script bytes **not** consensus encoding (which includes a length prefix). - #[inline] + #[inline] pub const fn as_bytes(&self) -> &[u8] { &self.0 } /// Returns the script data as a mutable byte slice. diff --git a/primitives/src/script/mod.rs b/primitives/src/script/mod.rs index 3a0244c59..a48f9c9b7 100644 --- a/primitives/src/script/mod.rs +++ b/primitives/src/script/mod.rs @@ -752,7 +752,6 @@ mod tests { assert!(WScriptHash::try_from(&script).is_err()); } - #[test] fn try_from_script_for_wscript_hash() { let script = Script::from_bytes(&[0x51; 10_000]); diff --git a/units/src/amount/mod.rs b/units/src/amount/mod.rs index 9a4f715ba..b08e6ebb4 100644 --- a/units/src/amount/mod.rs +++ b/units/src/amount/mod.rs @@ -604,9 +604,7 @@ impl CheckedSum for T where T: Iterator, { - fn checked_sum(mut self) -> Option { - self.try_fold(Amount::ZERO, Amount::checked_add) - } + fn checked_sum(mut self) -> Option { self.try_fold(Amount::ZERO, Amount::checked_add) } } impl CheckedSum for T diff --git a/units/src/fee.rs b/units/src/fee.rs index 009dd34df..f7eee0af5 100644 --- a/units/src/fee.rs +++ b/units/src/fee.rs @@ -13,10 +13,10 @@ use core::ops; -use crate::{Amount, FeeRate, MathOp, NumOpResult, OptionExt, Weight}; - use NumOpResult as R; +use crate::{Amount, FeeRate, MathOp, NumOpResult, OptionExt, Weight}; + impl Amount { /// Checked weight ceiling division. ///