Avoid clone() on a Copy type.

https://github.com/rust-lang-nursery/rust-clippy/wiki#clone_on_copy
This commit is contained in:
Dan Gohman
2017-08-31 11:48:14 -07:00
parent 105998944e
commit b6641ff443
4 changed files with 4 additions and 4 deletions

View File

@@ -136,7 +136,7 @@ impl<'short, 'long, Variable> InstBuilderBase<'short> for FuncInstBuilder<'short
match data.analyze_branch(&self.builder.func.dfg.value_lists) {
BranchInfo::SingleDest(_, args) => {
args.iter()
.map(|arg| self.builder.func.dfg.value_type(arg.clone()))
.map(|arg| self.builder.func.dfg.value_type(*arg))
.collect()
}
_ => panic!("should not happen"),