Skip to content

Commit

Permalink
clippy: fix a nightly clippy warning
Browse files Browse the repository at this point in the history
  • Loading branch information
ilyagr committed Nov 28, 2023
1 parent 28ab959 commit 3e96bf5
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions cli/src/commands/run.rs
Original file line number Diff line number Diff line change
Expand Up @@ -58,9 +58,7 @@ pub fn cmd_run(ui: &mut Ui, command: &CommandHelper, args: &RunArgs) -> Result<(
let _jobs = match args.jobs {
Some(0) => return Err(user_error("must pass at least one job")),
Some(jobs) => Some(jobs),
None => std::thread::available_parallelism()
.ok()
.and_then(|t| t.try_into().ok()),
None => std::thread::available_parallelism().map(|t| t.into()).ok(),
}
// Fallback to a single user-visible job.
.unwrap_or(1usize);
Expand Down

0 comments on commit 3e96bf5

Please sign in to comment.