Skip to content

Commit

Permalink
relax-trait-bounds (#56)
Browse files Browse the repository at this point in the history
  • Loading branch information
al8n authored Dec 23, 2024
1 parent f44378d commit 92fb870
Show file tree
Hide file tree
Showing 6 changed files with 5 additions and 133 deletions.
119 changes: 0 additions & 119 deletions .github/workflows/python.yml.bk

This file was deleted.

2 changes: 0 additions & 2 deletions core/src/state.rs
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,6 @@ impl<T, D> Memberlist<T, D>
where
D: Delegate<Id = T::Id, Address = <T::Resolver as AddressResolver>::ResolvedAddress>,
T: Transport,
T::Id: Send + Sync + 'static,
{
/// Does a complete state exchange with a specific node.
pub(crate) async fn push_pull_node(
Expand Down Expand Up @@ -578,7 +577,6 @@ enum StateMessage<T: Transport> {
impl<T> StateMessage<T>
where
T: Transport,
T::Id: Send + Sync + 'static,
{
async fn run<D>(self, s: &Memberlist<T, D>)
where
Expand Down
3 changes: 0 additions & 3 deletions core/src/suspicion.rs
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,6 @@ where
impl<T, D> Suspicioner<T, D>
where
T: Transport,
T::Id: Send + Sync + 'static,
D: Delegate<Id = T::Id, Address = <T::Resolver as AddressResolver>::ResolvedAddress>,
{
pub(crate) fn new(
Expand Down Expand Up @@ -138,7 +137,6 @@ where
impl<T, D> Suspicion<T, D>
where
T: Transport,
T::Id: Send + Sync + 'static,
D: Delegate<Id = T::Id, Address = <T::Resolver as AddressResolver>::ResolvedAddress>,
{
/// Returns a after_func started with the max time, and that will drive
Expand Down Expand Up @@ -180,7 +178,6 @@ where
impl<T, D> Suspicion<T, D>
where
T: Transport,
T::Id: Send + Sync + 'static,
D: Delegate<Id = T::Id, Address = <T::Resolver as AddressResolver>::ResolvedAddress>,
{
/// Confirm registers that a possibly new peer has also determined the given
Expand Down
2 changes: 1 addition & 1 deletion core/src/transport.rs
Original file line number Diff line number Diff line change
Expand Up @@ -273,7 +273,7 @@ pub trait Transport: Sized + Send + Sync + 'static {
/// The error type for the transport
type Error: TransportError;
/// The id type used to identify nodes
type Id: Id + Send + Sync + 'static;
type Id: Id;
/// The address resolver used to resolve addresses
type Resolver: AddressResolver<Runtime = Self::Runtime>;
/// The promised stream used to send and receive messages
Expand Down
6 changes: 2 additions & 4 deletions core/src/transport/lpe.rs
Original file line number Diff line number Diff line change
Expand Up @@ -47,10 +47,8 @@ impl<I, A> core::fmt::Display for Lpe<I, A> {

impl<I, A> Wire for Lpe<I, A>
where
I: Transformable + core::fmt::Debug + Send + Sync + 'static,
I::Error: Send + Sync + 'static,
A: Transformable + core::fmt::Debug + Send + Sync + 'static,
A::Error: Send + Sync + 'static,
I: Transformable + core::fmt::Debug,
A: Transformable + core::fmt::Debug,
{
type Error = MessageTransformError<I, A>;
type Id = I;
Expand Down
6 changes: 2 additions & 4 deletions types/src/message.rs
Original file line number Diff line number Diff line change
Expand Up @@ -186,10 +186,8 @@ const INLINED_BYTES_SIZE: usize = 64;

impl<I, A> Transformable for Message<I, A>
where
I: Transformable + core::fmt::Debug + 'static,
I::Error: Send + Sync + 'static,
A: Transformable + core::fmt::Debug + 'static,
A::Error: Send + Sync + 'static,
I: Transformable + core::fmt::Debug,
A: Transformable + core::fmt::Debug,
{
type Error = MessageTransformError<I, A>;

Expand Down

0 comments on commit 92fb870

Please sign in to comment.