aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--core/src/async_util/condvar.rs5
-rw-r--r--core/src/async_util/task_group.rs2
-rw-r--r--core/src/lib.rs1
-rw-r--r--jsonrpc/src/server/pubsub_service.rs2
-rw-r--r--jsonrpc/src/server/service.rs2
-rw-r--r--p2p/src/discovery/lookup.rs2
6 files changed, 6 insertions, 8 deletions
diff --git a/core/src/async_util/condvar.rs b/core/src/async_util/condvar.rs
index e425eda..44705c6 100644
--- a/core/src/async_util/condvar.rs
+++ b/core/src/async_util/condvar.rs
@@ -58,7 +58,6 @@ use crate::{async_runtime::lock::MutexGuard, util::random_16};
/// };
///
/// ```
-
pub struct CondVar {
inner: Mutex<Wakers>,
}
@@ -116,7 +115,7 @@ impl<'a, T> CondVarAwait<'a, T> {
}
}
-impl<'a, T> Future for CondVarAwait<'a, T> {
+impl<T> Future for CondVarAwait<'_, T> {
type Output = ();
fn poll(mut self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll<Self::Output> {
@@ -155,7 +154,7 @@ impl<'a, T> Future for CondVarAwait<'a, T> {
}
}
-impl<'a, T> Drop for CondVarAwait<'a, T> {
+impl<T> Drop for CondVarAwait<'_, T> {
fn drop(&mut self) {
if let Some(id) = self.id {
let mut inner = self.condvar.inner.lock();
diff --git a/core/src/async_util/task_group.rs b/core/src/async_util/task_group.rs
index c55b9a1..39bbf5c 100644
--- a/core/src/async_util/task_group.rs
+++ b/core/src/async_util/task_group.rs
@@ -126,7 +126,7 @@ pub struct TaskHandler {
cancel_flag: Arc<CondWait>,
}
-impl<'a> TaskHandler {
+impl TaskHandler {
/// Creates a new task handler
fn new<T, Fut, CallbackF, CallbackFut>(
ex: Executor,
diff --git a/core/src/lib.rs b/core/src/lib.rs
index a7192d9..fedb226 100644
--- a/core/src/lib.rs
+++ b/core/src/lib.rs
@@ -23,7 +23,6 @@ pub mod pubsub;
pub mod async_runtime;
#[cfg(feature = "crypto")]
-
/// Collects common cryptographic tools
pub mod crypto;
diff --git a/jsonrpc/src/server/pubsub_service.rs b/jsonrpc/src/server/pubsub_service.rs
index 909b0b0..0775880 100644
--- a/jsonrpc/src/server/pubsub_service.rs
+++ b/jsonrpc/src/server/pubsub_service.rs
@@ -12,6 +12,6 @@ type PubSubRPCMethodOutput<'a> =
/// Defines the interface for an RPC service.
pub trait PubSubRPCService: Sync + Send {
- fn get_pubsub_method<'a>(&'a self, name: &'a str) -> Option<PubSubRPCMethod>;
+ fn get_pubsub_method(&self, name: &str) -> Option<PubSubRPCMethod>;
fn name(&self) -> String;
}
diff --git a/jsonrpc/src/server/service.rs b/jsonrpc/src/server/service.rs
index 787da86..5195d2c 100644
--- a/jsonrpc/src/server/service.rs
+++ b/jsonrpc/src/server/service.rs
@@ -9,6 +9,6 @@ type RPCMethodOutput<'a> =
/// Defines the interface for an RPC service.
pub trait RPCService: Sync + Send {
- fn get_method<'a>(&'a self, name: &'a str) -> Option<RPCMethod>;
+ fn get_method(&self, name: &str) -> Option<RPCMethod>;
fn name(&self) -> String;
}
diff --git a/p2p/src/discovery/lookup.rs b/p2p/src/discovery/lookup.rs
index ba15da3..71cc5b8 100644
--- a/p2p/src/discovery/lookup.rs
+++ b/p2p/src/discovery/lookup.rs
@@ -215,7 +215,7 @@ impl LookupService {
/// Starts a self lookup
async fn self_lookup(
&self,
- random_peers: &Vec<PeerMsg>,
+ random_peers: &[PeerMsg],
peer_buffer: &mut Vec<PeerMsg>,
) -> Result<()> {
let mut results = FuturesUnordered::new();