File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -530,11 +530,12 @@ impl<'a> Arbitrary<'a> for MerkleBlock {
530530
531531#[ cfg( test) ]
532532mod tests {
533- use hex:: { DisplayHex , FromHex } ;
534- use hex_lit:: hex;
535533 #[ cfg( feature = "std" ) ]
536534 use core:: cmp;
537535
536+ use hex:: { DisplayHex , FromHex } ;
537+ use hex_lit:: hex;
538+
538539 use super :: * ;
539540 use crate :: block:: Unchecked ;
540541 use crate :: consensus:: encode;
@@ -555,11 +556,7 @@ mod tests {
555556 const P : usize = 1039 ;
556557 const Q : usize = 677 ;
557558
558- const fn new ( seed : usize ) -> Self {
559- Self {
560- state : seed
561- }
562- }
559+ const fn new ( seed : usize ) -> Self { Self { state : seed } }
563560
564561 #[ inline]
565562 fn next_usize ( & mut self ) -> usize {
@@ -568,14 +565,10 @@ mod tests {
568565 }
569566
570567 #[ inline]
571- fn next_in_range ( & mut self , max : usize ) -> usize {
572- self . next_usize ( ) % max
573- }
568+ fn next_in_range ( & mut self , max : usize ) -> usize { self . next_usize ( ) % max }
574569
575570 #[ inline]
576- fn next_u8 ( & mut self ) -> u8 {
577- self . next_usize ( ) . to_le_bytes ( ) [ 0 ]
578- }
571+ fn next_u8 ( & mut self ) -> u8 { self . next_usize ( ) . to_le_bytes ( ) [ 0 ] }
579572 }
580573
581574 #[ cfg( feature = "std" ) ]
Original file line number Diff line number Diff line change @@ -197,7 +197,7 @@ pub mod as_core_arg {
197197 #![ allow( clippy:: missing_errors_doc) ]
198198
199199 use crate :: Network ;
200-
200+
201201 #[ allow( clippy:: trivially_copy_pass_by_ref) ] // `serde` controls the API.
202202 pub fn serialize < S > ( network : & Network , serializer : S ) -> Result < S :: Ok , S :: Error >
203203 where
You can’t perform that action at this time.
0 commit comments