Skip to content

Commit afec0ab

Browse files
committed
Bless clippy
1 parent 92b837b commit afec0ab

File tree

2 files changed

+3
-6
lines changed

2 files changed

+3
-6
lines changed

src/tools/miri/miri-script/src/commands.rs

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -252,12 +252,11 @@ impl Command {
252252
// Fetch given rustc commit.
253253
cmd!(sh, "git fetch http://localhost:{JOSH_PORT}/rust-lang/rust.git@{commit}{JOSH_FILTER}.git")
254254
.run()
255-
.map_err(|e| {
255+
.inspect_err(|_| {
256256
// Try to un-do the previous `git commit`, to leave the repo in the state we found it.
257257
cmd!(sh, "git reset --hard HEAD^")
258258
.run()
259259
.expect("FAILED to clean up again after failed `git fetch`, sorry for that");
260-
e
261260
})
262261
.context("FAILED to fetch new commits, something went wrong (committing the rust-version file has been undone)")?;
263262

@@ -545,9 +544,8 @@ impl Command {
545544
if let Some(seed_range) = many_seeds {
546545
e.run_many_times(seed_range, |sh, seed| {
547546
eprintln!("Trying seed: {seed}");
548-
run_miri(sh, Some(format!("-Zmiri-seed={seed}"))).map_err(|err| {
547+
run_miri(sh, Some(format!("-Zmiri-seed={seed}"))).inspect_err(|_| {
549548
eprintln!("FAILING SEED: {seed}");
550-
err
551549
})
552550
})?;
553551
} else {

src/tools/miri/miri-script/src/util.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -219,10 +219,9 @@ impl MiriEnv {
219219
break;
220220
}
221221
// Run the command with this seed.
222-
run(&local_shell, cur).map_err(|err| {
222+
run(&local_shell, cur).inspect_err(|_| {
223223
// If we failed, tell everyone about this.
224224
failed.store(true, Ordering::Relaxed);
225-
err
226225
})?;
227226
// Check if some other command failed (in which case we'll stop as well).
228227
if failed.load(Ordering::Relaxed) {

0 commit comments

Comments
 (0)