mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-27 04:19:13 +00:00
Track labels in scopes
This commit is contained in:
parent
090e013161
commit
cbd325707b
4 changed files with 57 additions and 11 deletions
|
@ -839,6 +839,10 @@ impl<'a> SemanticsScope<'a> {
|
|||
let parent = resolver.body_owner().unwrap();
|
||||
ScopeDef::Local(Local { parent, pat_id })
|
||||
}
|
||||
resolver::ScopeDef::Label(label_id) => {
|
||||
let parent = resolver.body_owner().unwrap();
|
||||
ScopeDef::Label(Label { parent, label_id })
|
||||
}
|
||||
};
|
||||
f(name, def)
|
||||
})
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue