resolve: Use NameBinding for local variables and generic parameters
This commit is contained in:
@@ -1294,7 +1294,8 @@ impl<'a: 'ast, 'ast> LateResolutionVisitor<'a, '_, 'ast> {
|
||||
// Walk backwards up the ribs in scope and collect candidates.
|
||||
for rib in self.ribs[ns].iter().rev() {
|
||||
// Locals and type parameters
|
||||
for (ident, &res) in &rib.bindings {
|
||||
for (ident, binding) in &rib.bindings {
|
||||
let res = binding.res();
|
||||
if filter_fn(res) {
|
||||
names.push(TypoSuggestion::typo_from_res(ident.name, res));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user