add clippy::use_self for cleanliness

This commit is contained in:
Benjamin Fry
2022-02-17 18:01:13 -08:00
parent 96c7f96921
commit 95b2dee327
128 changed files with 791 additions and 796 deletions

View File

@@ -11,6 +11,7 @@
clippy::dbg_macro,
clippy::print_stdout,
clippy::unimplemented,
clippy::use_self,
missing_copy_implementations,
missing_docs,
non_snake_case,

View File

@@ -96,7 +96,7 @@ impl Connect for AsyncStdTcpStream {
None => async_std::net::TcpStream::connect(addr).await?,
};
stream.set_nodelay(true)?;
Ok(AsyncStdTcpStream(stream))
Ok(Self(stream))
}
}

View File

@@ -49,7 +49,7 @@ pub struct AsyncStdRuntime;
impl Executor for AsyncStdRuntime {
fn new() -> Self {
AsyncStdRuntime {}
Self {}
}
fn block_on<F: Future>(&mut self, future: F) -> F::Output {