resolve: Partially unify early and late scope-relative ident resolution
This commit is contained in:
parent
afaf33dcaf
commit
ee0357af3b
5 changed files with 97 additions and 144 deletions
|
@ -606,7 +606,7 @@ impl<'a> Resolver<'a> {
|
|||
/// Lookup typo candidate in scope for a macro or import.
|
||||
fn early_lookup_typo_candidate(
|
||||
&mut self,
|
||||
scope_set: ScopeSet,
|
||||
scope_set: ScopeSet<'a>,
|
||||
parent_scope: &ParentScope<'a>,
|
||||
ident: Ident,
|
||||
filter_fn: &impl Fn(Res) -> bool,
|
||||
|
@ -662,7 +662,7 @@ impl<'a> Resolver<'a> {
|
|||
let root_module = this.resolve_crate_root(root_ident);
|
||||
this.add_module_candidates(root_module, &mut suggestions, filter_fn);
|
||||
}
|
||||
Scope::Module(module) => {
|
||||
Scope::Module(module, _) => {
|
||||
this.add_module_candidates(module, &mut suggestions, filter_fn);
|
||||
}
|
||||
Scope::RegisteredAttrs => {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue