Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'crates/hir-ty/src/upvars.rs')
| -rw-r--r-- | crates/hir-ty/src/upvars.rs | 18 |
1 files changed, 1 insertions, 17 deletions
diff --git a/crates/hir-ty/src/upvars.rs b/crates/hir-ty/src/upvars.rs index 48f3c803d8..026e6ab183 100644 --- a/crates/hir-ty/src/upvars.rs +++ b/crates/hir-ty/src/upvars.rs @@ -3,7 +3,7 @@ use hir_def::{ DefWithBodyId, ExpressionStoreOwnerId, GenericDefId, VariantId, expr_store::{ExpressionStore, path::Path}, - hir::{BindingId, Expr, ExprId, ExprOrPatId, Pat}, + hir::{BindingId, Expr, ExprId, ExprOrPatId}, resolver::{HasResolver, Resolver, ValueNs}, }; use hir_expand::mod_path::PathKind; @@ -181,22 +181,6 @@ pub fn upvars_mentioned_impl( path, ); } - &Expr::Assignment { target, .. } => { - body.walk_pats(target, &mut |pat| { - let Pat::Path(path) = &body[pat] else { return }; - resolve_maybe_upvar( - db, - resolver, - owner, - body, - current_closure, - expr, - pat.into(), - upvars, - path, - ); - }); - } &Expr::Closure { body: body_expr, .. } => { let mut closure_upvars = FxHashSet::default(); handle_expr_inside_closure( |