1
Fork 0

don't clone copy types

This commit is contained in:
Matthias Krüger 2020-12-29 19:33:48 +01:00
parent 158f8d034b
commit 17a8c1017f
6 changed files with 10 additions and 10 deletions

View file

@ -74,7 +74,7 @@ crate fn krate(mut cx: &mut DocContext<'_>) -> Crate {
)
}));
m.items.extend(keywords.into_iter().map(|(def_id, kw)| {
Item::from_def_id_and_parts(def_id, Some(kw.clone()), ItemKind::KeywordItem(kw), cx)
Item::from_def_id_and_parts(def_id, Some(kw), ItemKind::KeywordItem(kw), cx)
}));
}
@ -307,7 +307,7 @@ crate fn strip_path(path: &Path) -> Path {
.segments
.iter()
.map(|s| PathSegment {
name: s.name.clone(),
name: s.name,
args: GenericArgs::AngleBracketed { args: vec![], bindings: vec![] },
})
.collect();