Do not resolve elided lifetimes in path twice.

This commit is contained in:
Camille GILLOT 2022-04-21 18:39:43 +02:00
parent 38a4c2cc44
commit 69985f0175

View file

@ -2655,9 +2655,9 @@ fn smart_resolve_path_fragment(
if !matches!(source, PathSource::TraitItem(..)) {
// Avoid recording definition of `A::B` in `<T as A>::B::C`.
self.r.record_partial_res(id, partial_res);
self.resolve_elided_lifetimes_in_path(id, partial_res, path, source, finalize);
}
self.resolve_elided_lifetimes_in_path(id, partial_res, path, source, finalize);
partial_res
}