Skip to content

Commit 082d576

Browse files
authored
Rollup merge of rust-lang#83526 - klensy:lazy-too, r=petrochenkov
lazily calls some fns Replaced some fn's with it's lazy variants.
2 parents 56be326 + b38cc7b commit 082d576

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

test/src/helpers/exit_code.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ use std::process::ExitStatus;
44

55
#[cfg(not(unix))]
66
pub fn get_exit_code(status: ExitStatus) -> Result<i32, String> {
7-
status.code().ok_or("received no exit code from child process".into())
7+
status.code().ok_or_else(|| "received no exit code from child process".into())
88
}
99

1010
#[cfg(unix)]

0 commit comments

Comments
 (0)