Skip to content

Commit

Permalink
Clippy
Browse files Browse the repository at this point in the history
  • Loading branch information
ivmarkov committed Nov 28, 2024
1 parent 820e36a commit d8da29e
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 15 deletions.
4 changes: 2 additions & 2 deletions src/eth.rs
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ where
pub type EthMatterStack<'a, E> = MatterStack<'a, Eth<E>>;

/// A specialization of the `MatterStack` for Ethernet.
impl<'a, E> MatterStack<'a, Eth<E>>
impl<E> MatterStack<'_, Eth<E>>
where
E: Embedding + 'static,
{
Expand Down Expand Up @@ -110,7 +110,7 @@ where
/// - `persist` - a user-provided `Persist` implementation
/// - `handler` - a user-provided DM handler implementation
/// - `user` - a user-provided future that will be polled only when the netif interface is up
pub async fn run<'d, N, P, H, U>(
pub async fn run<N, P, H, U>(
&self,
netif: N,
persist: P,
Expand Down
4 changes: 2 additions & 2 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -319,7 +319,7 @@ where
/// - `comm` - a tuple of additional and optional `NetworkReceive` and `NetworkSend` transport implementations
/// (useful when a second transport needs to run in parallel with the operational Matter transport,
/// i.e. when using concurrent commissisoning)
async fn run_oper_net<'d, I, U, R, S>(
async fn run_oper_net<I, U, R, S>(
&self,
netif: I,
until: U,
Expand Down Expand Up @@ -444,7 +444,7 @@ where
/// user-provided transport might not be IP-based (i.e. BLE).
///
/// It also has no facilities for monitoring the transport network state.
async fn run_handlers<'d, P, H>(&self, persist: P, handler: H) -> Result<(), Error>
async fn run_handlers<P, H>(&self, persist: P, handler: H) -> Result<(), Error>
where
H: AsyncHandler + AsyncMetadata,
P: Persist,
Expand Down
2 changes: 1 addition & 1 deletion src/persist.rs
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ where
}
}

impl<'a, T, C> Persist for KvPersist<'a, T, C>
impl<T, C> Persist for KvPersist<'_, T, C>
where
T: KvBlobStore,
C: NetworkPersist,
Expand Down
18 changes: 9 additions & 9 deletions src/wireless.rs
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@ pub type WifiNCMatterStack<'a, M, E> = MatterStack<'a, WirelessBle<M, Wifi<NC>,
/// Note that Alexa does not (yet) work with non-concurrent commissioning.
pub type ThreadNCMatterStack<'a, M, E> = MatterStack<'a, WirelessBle<M, Thread<NC>, E>>;

impl<'a, M, T, E> MatterStack<'a, WirelessBle<M, T, E>>
impl<M, T, E> MatterStack<'_, WirelessBle<M, T, E>>
where
M: RawMutex + Send + Sync + 'static,
T: ConcurrentWirelessConfig,
Expand All @@ -199,7 +199,7 @@ where
/// - `persist` - a user-provided `Persist` implementation
/// - `handler` - a user-provided DM handler implementation
/// - `user` - a user-provided future that will be polled only when the netif interface is up
pub async fn run_with_controller<'d, C, N, B, P, H, U>(
pub async fn run_with_controller<C, N, B, P, H, U>(
&'static self,
controller: C,
netif: N,
Expand Down Expand Up @@ -234,7 +234,7 @@ where
}
}

impl<'a, M, T, E> MatterStack<'a, WirelessBle<M, T, E>>
impl<M, T, E> MatterStack<'_, WirelessBle<M, T, E>>
where
M: RawMutex + Send + Sync + 'static,
T: WirelessConfig,
Expand All @@ -260,7 +260,7 @@ where
/// - `persist` - a user-provided `Persist` implementation
/// - `handler` - a user-provided DM handler implementation
/// - `user` - a user-provided future that will be polled only when the netif interface is up
pub async fn run<'d, W, B, P, H, U>(
pub async fn run<W, B, P, H, U>(
&'static self,
wireless: W,
ble: B,
Expand Down Expand Up @@ -292,7 +292,7 @@ where
.await
}

async fn run_net<'d, W, B>(&'static self, mut wireless: W, mut ble: B) -> Result<(), Error>
async fn run_net<W, B>(&'static self, mut wireless: W, mut ble: B) -> Result<(), Error>
where
W: Wireless<Data = T::Data>,
B: Ble,
Expand Down Expand Up @@ -359,7 +359,7 @@ where
}
}

async fn run_net_with_controller<'d, C, N, B>(
async fn run_net_with_controller<C, N, B>(
&'static self,
mut controller: C,
netif: N,
Expand Down Expand Up @@ -419,7 +419,7 @@ where
}
}

async fn run_comm_net<'d, N, B>(
async fn run_comm_net<N, B>(
&self,
mut netif: N,
btp: &Btp<&'static BtpContext<M>, M, B>,
Expand All @@ -443,7 +443,7 @@ where
select(&mut btp_task, &mut net_task).coalesce().await
}

async fn run_nc_comm_net<'d, B>(
async fn run_nc_comm_net<B>(
&'static self,
btp: &Btp<&'static BtpContext<M>, M, B>,
) -> Result<(), Error>
Expand Down Expand Up @@ -609,7 +609,7 @@ mod bluez {
}
}

impl<'a> Ble for BuiltinBle<'a> {
impl Ble for BuiltinBle<'_> {
type Peripheral<'t>
= BuiltinGattPeripheral
where
Expand Down
2 changes: 1 addition & 1 deletion src/wireless/comm.rs
Original file line number Diff line number Diff line change
Expand Up @@ -535,7 +535,7 @@ where
}
}

impl<'a, const N: usize, M, T> AsyncHandler for WirelessNwCommCluster<'a, N, M, T>
impl<const N: usize, M, T> AsyncHandler for WirelessNwCommCluster<'_, N, M, T>
where
M: RawMutex,
T: Controller,
Expand Down

0 comments on commit d8da29e

Please sign in to comment.