1
Fork 0

Simplified name mapping in auto trait handling.

This commit is contained in:
Inokentiy Babushkin 2018-04-15 15:47:56 +02:00
parent d101753cd8
commit 388defad2d
No known key found for this signature in database
GPG key ID: 7EFC8EC5224DE8EC
2 changed files with 4 additions and 6 deletions

View file

@ -290,7 +290,7 @@ impl<'a, 'tcx, 'rcx> AutoTraitFinder<'a, 'tcx, 'rcx> {
let names_map =
info.names_map
.drain()
.map(|(name, lifetime)| (name, Lifetime(lifetime)))
.map(|name| (name.clone(), Lifetime(name)))
.collect();
let lifetime_predicates =
self.handle_lifetimes(&region_data, &names_map);