Skip to content

Commit caa2338

Browse files
committed
fix clippy warning
1 parent eeb44c8 commit caa2338

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

src/io/stderr.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ impl Stderr {
120120
/// # Ok(()) }) }
121121
/// ```
122122
pub async fn lock(&self) -> StderrLock<'static> {
123-
static STDERR: Lazy<std::io::Stderr> = Lazy::new(|| std::io::stderr());
123+
static STDERR: Lazy<std::io::Stderr> = Lazy::new(std::io::stderr);
124124

125125
blocking::spawn(move || StderrLock(STDERR.lock())).await
126126
}

src/io/stdin.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,7 @@ impl Stdin {
176176
/// # Ok(()) }) }
177177
/// ```
178178
pub async fn lock(&self) -> StdinLock<'static> {
179-
static STDIN: Lazy<std::io::Stdin> = Lazy::new(|| std::io::stdin());
179+
static STDIN: Lazy<std::io::Stdin> = Lazy::new(std::io::stdin);
180180

181181
blocking::spawn(move || StdinLock(STDIN.lock())).await
182182
}

src/io/stdout.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ impl Stdout {
120120
/// # Ok(()) }) }
121121
/// ```
122122
pub async fn lock(&self) -> StdoutLock<'static> {
123-
static STDOUT: Lazy<std::io::Stdout> = Lazy::new(|| std::io::stdout());
123+
static STDOUT: Lazy<std::io::Stdout> = Lazy::new(std::io::stdout);
124124

125125
blocking::spawn(move || StdoutLock(STDOUT.lock())).await
126126
}

0 commit comments

Comments
 (0)