resolve: Tweak some naming around import ambiguities

This commit is contained in:
Vadim Petrochenkov
2024-06-25 19:03:39 +03:00
parent d929a42a66
commit b6074fffd1
4 changed files with 42 additions and 50 deletions

View File

@@ -3730,7 +3730,7 @@ impl<'a: 'ast, 'b, 'ast, 'tcx> LateResolutionVisitor<'a, 'b, 'ast, 'tcx> {
let ls_binding = self.maybe_resolve_ident_in_lexical_scope(ident, ValueNS)?;
let (res, binding) = match ls_binding {
LexicalScopeBinding::Item(binding)
if is_syntactic_ambiguity && binding.is_ambiguity() =>
if is_syntactic_ambiguity && binding.is_ambiguity_recursive() =>
{
// For ambiguous bindings we don't know all their definitions and cannot check
// whether they can be shadowed by fresh bindings or not, so force an error.