Skip to content

Commit

Permalink
Run formmater on bip152
Browse files Browse the repository at this point in the history
Run the formmater on the newly moved `bip152` module. No changes other
than those introduced by `cargo +nightly fmt`.
  • Loading branch information
tcharding committed Sep 14, 2022
1 parent 9b35845 commit 1ac02b8
Showing 1 changed file with 7 additions and 10 deletions.
17 changes: 7 additions & 10 deletions bitcoin/src/bip152.rs
Expand Up @@ -5,18 +5,17 @@
//! Implementation of compact blocks data structure and algorithms.
//!

use crate::prelude::*;

use crate::io;
use core::{convert, convert::TryFrom, fmt, mem};
use core::convert::TryFrom;
use core::{convert, fmt, mem};
#[cfg(feature = "std")]
use std::error;

use crate::consensus::encode::{self, Decodable, Encodable, VarInt};
use crate::hashes::{sha256, siphash24, Hash};
use crate::internal_macros::{impl_array_newtype, impl_bytes_newtype, impl_consensus_encoding};
use crate::prelude::*;
use crate::util::endian;
use crate::{Block, BlockHash, BlockHeader, Transaction};
use crate::{io, Block, BlockHash, BlockHeader, Transaction};

/// A BIP-152 error
#[derive(Clone, PartialEq, Eq, Debug, Copy, PartialOrd, Ord, Hash)]
Expand Down Expand Up @@ -69,9 +68,7 @@ pub struct PrefilledTransaction {
}

impl convert::AsRef<Transaction> for PrefilledTransaction {
fn as_ref(&self) -> &Transaction {
&self.tx
}
fn as_ref(&self) -> &Transaction { &self.tx }
}

impl Encodable for PrefilledTransaction {
Expand Down Expand Up @@ -376,8 +373,8 @@ mod test {
use crate::consensus::encode::{deserialize, serialize};
use crate::hashes::hex::FromHex;
use crate::{
Block, BlockHash, BlockHeader, BlockVersion, OutPoint, Script, Sequence, Transaction, TxIn, TxMerkleNode,
TxOut, Txid, Witness,
Block, BlockHash, BlockHeader, BlockVersion, OutPoint, Script, Sequence, Transaction, TxIn,
TxMerkleNode, TxOut, Txid, Witness,
};

fn dummy_tx(nonce: &[u8]) -> Transaction {
Expand Down

0 comments on commit 1ac02b8

Please sign in to comment.