1
Fork 0

Remove redundant clone

This commit is contained in:
Shotaro Yamada 2018-11-28 12:19:22 +09:00
parent 0c999ed132
commit 65aa0a6249
2 changed files with 2 additions and 2 deletions

View file

@ -318,7 +318,7 @@ impl<'a, 'cl> Resolver<'a, 'cl> {
// This particular use tree
&tree, id, &prefix, true,
// The whole `use` item
parent_scope.clone(), item, ty::Visibility::Invisible, root_span,
parent_scope, item, ty::Visibility::Invisible, root_span,
);
}
}

View file

@ -309,7 +309,7 @@ fn create_matches(len: usize) -> Box<[Rc<NamedMatchVec>]> {
vec![]
} else {
let empty_matches = Rc::new(SmallVec::new());
vec![empty_matches.clone(); len]
vec![empty_matches; len]
}.into_boxed_slice()
}