mirror of
https://github.com/hl-archive-node/nanoreth.git
synced 2025-12-06 10:59:55 +00:00
add use_self clippy lint (#8325)
This commit is contained in:
@ -560,7 +560,7 @@ impl TaskSpawner for TaskExecutor {
|
||||
|
||||
fn spawn_critical(&self, name: &'static str, fut: BoxFuture<'static, ()>) -> JoinHandle<()> {
|
||||
self.metrics.inc_critical_tasks();
|
||||
TaskExecutor::spawn_critical(self, name, fut)
|
||||
Self::spawn_critical(self, name, fut)
|
||||
}
|
||||
|
||||
fn spawn_blocking(&self, fut: BoxFuture<'static, ()>) -> JoinHandle<()> {
|
||||
@ -572,7 +572,7 @@ impl TaskSpawner for TaskExecutor {
|
||||
name: &'static str,
|
||||
fut: BoxFuture<'static, ()>,
|
||||
) -> JoinHandle<()> {
|
||||
TaskExecutor::spawn_critical_blocking(self, name, fut)
|
||||
Self::spawn_critical_blocking(self, name, fut)
|
||||
}
|
||||
}
|
||||
|
||||
@ -610,7 +610,7 @@ impl TaskSpawnerExt for TaskExecutor {
|
||||
where
|
||||
F: Future<Output = ()> + Send + 'static,
|
||||
{
|
||||
TaskExecutor::spawn_critical_with_graceful_shutdown_signal(self, name, f)
|
||||
Self::spawn_critical_with_graceful_shutdown_signal(self, name, f)
|
||||
}
|
||||
|
||||
fn spawn_with_graceful_shutdown_signal<F>(
|
||||
@ -620,7 +620,7 @@ impl TaskSpawnerExt for TaskExecutor {
|
||||
where
|
||||
F: Future<Output = ()> + Send + 'static,
|
||||
{
|
||||
TaskExecutor::spawn_with_graceful_shutdown_signal(self, f)
|
||||
Self::spawn_with_graceful_shutdown_signal(self, f)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -42,7 +42,7 @@ impl fmt::Debug for IncCounterOnDrop {
|
||||
impl IncCounterOnDrop {
|
||||
/// Creates a new instance of `IncCounterOnDrop` with the given counter.
|
||||
pub fn new(counter: Counter) -> Self {
|
||||
IncCounterOnDrop(counter)
|
||||
Self(counter)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user