mirror of
https://github.com/rust-lang/rust.git
synced 2025-04-10 02:56:52 +00:00
Avoid two-phase borrow conflict
This commit is contained in:
parent
1e2178eb8e
commit
61c09edb4a
@ -489,8 +489,8 @@ impl<'a, D: HirDatabase> InferenceContext<'a, D> {
|
||||
Some(ty)
|
||||
}
|
||||
Resolution::LocalBinding(pat) => {
|
||||
let ty = self.type_of_pat.get(pat)?;
|
||||
let ty = self.resolve_ty_as_possible(&mut vec![], ty.clone());
|
||||
let ty = self.type_of_pat.get(pat)?.clone();
|
||||
let ty = self.resolve_ty_as_possible(&mut vec![], ty);
|
||||
Some(ty)
|
||||
}
|
||||
Resolution::GenericParam(..) => {
|
||||
|
Loading…
Reference in New Issue
Block a user