Skip to content

Commit 47de5b4

Browse files
committed
Remove collect
1 parent ec4bcaa commit 47de5b4

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/librustdoc/core.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -492,9 +492,9 @@ impl<'tcx> Visitor<'tcx> for EmitIgnoredResolutionErrors<'tcx> {
492492
"could not resolve path `{}`",
493493
path.segments
494494
.iter()
495-
.map(|segment| segment.ident.as_str().to_string())
496-
.collect::<Vec<_>>()
497-
.join("::")
495+
.map(|segment| segment.ident.as_str())
496+
.intersperse("::")
497+
.collect::<String>()
498498
);
499499
let mut err = rustc_errors::struct_span_err!(
500500
self.tcx.sess,

0 commit comments

Comments
 (0)