Skip to content

Commit

Permalink
chore(chain): stop clippy from complaining
Browse files Browse the repository at this point in the history
  • Loading branch information
evanlinjin committed Jul 1, 2024
1 parent ff87f0e commit e6ec3f1
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 8 deletions.
6 changes: 0 additions & 6 deletions crates/chain/src/changeset.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/// A changeset containing [`crate`] structures typically persisted together.
#[cfg(feature = "miniscript")]
#[derive(Debug, Clone, PartialEq)]
#[cfg_attr(
feature = "serde",
Expand All @@ -21,7 +20,6 @@ pub struct CombinedChangeSet<K, A> {
pub network: Option<bitcoin::Network>,
}

#[cfg(feature = "miniscript")]
impl<K, A> core::default::Default for CombinedChangeSet<K, A> {
fn default() -> Self {
Self {
Expand All @@ -32,7 +30,6 @@ impl<K, A> core::default::Default for CombinedChangeSet<K, A> {
}
}

#[cfg(feature = "miniscript")]
impl<K: Ord, A: crate::Anchor> crate::Append for CombinedChangeSet<K, A> {
fn append(&mut self, other: Self) {
crate::Append::append(&mut self.chain, other.chain);
Expand All @@ -51,7 +48,6 @@ impl<K: Ord, A: crate::Anchor> crate::Append for CombinedChangeSet<K, A> {
}
}

#[cfg(feature = "miniscript")]
impl<K, A> From<crate::local_chain::ChangeSet> for CombinedChangeSet<K, A> {
fn from(chain: crate::local_chain::ChangeSet) -> Self {
Self {
Expand All @@ -61,7 +57,6 @@ impl<K, A> From<crate::local_chain::ChangeSet> for CombinedChangeSet<K, A> {
}
}

#[cfg(feature = "miniscript")]
impl<K, A> From<crate::indexed_tx_graph::ChangeSet<A, crate::keychain::ChangeSet<K>>>
for CombinedChangeSet<K, A>
{
Expand All @@ -75,7 +70,6 @@ impl<K, A> From<crate::indexed_tx_graph::ChangeSet<A, crate::keychain::ChangeSet
}
}

#[cfg(feature = "miniscript")]
impl<K, A> From<crate::keychain::ChangeSet<K>> for CombinedChangeSet<K, A> {
fn from(indexer: crate::keychain::ChangeSet<K>) -> Self {
Self {
Expand Down
2 changes: 1 addition & 1 deletion crates/chain/src/keychain.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
#[cfg(feature = "miniscript")]
mod txout_index;
use bitcoin::{Amount, ScriptBuf};
use bitcoin::Amount;
#[cfg(feature = "miniscript")]
pub use txout_index::*;

Expand Down
2 changes: 1 addition & 1 deletion crates/chain/src/keychain/txout_index.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ use crate::{
DescriptorExt, DescriptorId, SpkIterator, SpkTxOutIndex,
};
use alloc::{borrow::ToOwned, vec::Vec};
use bitcoin::{Amount, OutPoint, Script, SignedAmount, Transaction, TxOut, Txid};
use bitcoin::{Amount, OutPoint, Script, ScriptBuf, SignedAmount, Transaction, TxOut, Txid};
use core::{
fmt::Debug,
ops::{Bound, RangeBounds},
Expand Down
2 changes: 2 additions & 0 deletions crates/chain/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,9 @@ pub use descriptor_ext::{DescriptorExt, DescriptorId};
mod spk_iter;
#[cfg(feature = "miniscript")]
pub use spk_iter::*;
#[cfg(feature = "miniscript")]
mod changeset;
#[cfg(feature = "miniscript")]
pub use changeset::*;
pub mod spk_client;

Expand Down

0 comments on commit e6ec3f1

Please sign in to comment.