Skip to content

Commit fba3d79

Browse files
committed
Auto merge of rust-lang#2743 - RalfJung:path-join, r=RalfJung
simplify path joining code a bit
2 parents fbdf926 + 041ad1f commit fba3d79

File tree

1 file changed

+1
-9
lines changed

1 file changed

+1
-9
lines changed

src/tools/miri/cargo-miri/src/phases.rs

+1-9
Original file line numberDiff line numberDiff line change
@@ -265,15 +265,7 @@ pub fn phase_rustc(mut args: impl Iterator<Item = String>, phase: RustcPhase) {
265265
);
266266
let output =
267267
String::from_utf8(output.stdout).expect("rustc returned non-UTF-8 filename");
268-
output
269-
.lines()
270-
.filter(|l| !l.is_empty())
271-
.map(|l| {
272-
let mut p = path.clone();
273-
p.push(l);
274-
p
275-
})
276-
.collect()
268+
output.lines().filter(|l| !l.is_empty()).map(|l| path.join(l)).collect()
277269
}
278270
}
279271

0 commit comments

Comments
 (0)