Skip to content

Commit

Permalink
chore: debug/copy/clone derives (#282)
Browse files Browse the repository at this point in the history
  • Loading branch information
onbjerg authored Mar 12, 2024
1 parent 388dad1 commit e967ddb
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 1 deletion.
4 changes: 4 additions & 0 deletions crates/providers/src/builder.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ pub trait ProviderLayer<P: Provider<N, T>, N: Network, T: Transport + Clone> {
}

/// An identity layer that does nothing.
#[derive(Debug, Clone, Copy)]
pub struct Identity;

impl<P, N, T> ProviderLayer<P, N, T> for Identity
Expand All @@ -32,6 +33,8 @@ where
}
}

/// A stack of two providers.
#[derive(Debug)]
pub struct Stack<Inner, Outer> {
inner: Inner,
outer: Outer,
Expand Down Expand Up @@ -67,6 +70,7 @@ where
/// around maintaining the network and transport types.
///
/// [`tower::ServiceBuilder`]: https://docs.rs/tower/latest/tower/struct.ServiceBuilder.html
#[derive(Debug)]
pub struct ProviderBuilder<L, N = ()> {
layer: L,

Expand Down
2 changes: 1 addition & 1 deletion crates/providers/src/heart.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ use tokio::{
};

/// A configuration object for watching for transaction confirmation.
#[derive(Debug)]
#[derive(Debug, Clone, Copy)]
pub struct WatchConfig {
/// The transaction hash to watch for.
tx_hash: B256,
Expand Down
1 change: 1 addition & 0 deletions crates/providers/src/signer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ where
/// You cannot construct this provider directly. Use [`ProviderBuilder`] with a [`SignerLayer`].
///
/// [`ProviderBuilder`]: crate::ProviderBuilder
#[derive(Debug)]
pub struct SignerProvider<N, T, P, S>
where
N: Network,
Expand Down

0 comments on commit e967ddb

Please sign in to comment.