Skip to content

Commit

Permalink
Remove Resolver::empty_disambiguator.
Browse files Browse the repository at this point in the history
It was added in #115367 for anonymous ADTs. Those changes were then
reverted in #131045, but `empty_disambiguator` was left behind, perhaps
by mistake. It seems to be unnecessary.
  • Loading branch information
nnethercote committed Nov 14, 2024
1 parent 66cc7d6 commit 12747f1
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions compiler/rustc_resolve/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1082,8 +1082,6 @@ pub struct Resolver<'ra, 'tcx> {
binding_parent_modules: FxHashMap<NameBinding<'ra>, Module<'ra>>,

underscore_disambiguator: u32,
/// Disambiguator for anonymous adts.
empty_disambiguator: u32,

/// Maps glob imports to the names of items actually imported.
glob_map: FxHashMap<LocalDefId, FxHashSet<Symbol>>,
Expand Down Expand Up @@ -1462,7 +1460,6 @@ impl<'ra, 'tcx> Resolver<'ra, 'tcx> {
module_children: Default::default(),
trait_map: NodeMap::default(),
underscore_disambiguator: 0,
empty_disambiguator: 0,
empty_module,
module_map,
block_map: Default::default(),
Expand Down Expand Up @@ -1841,9 +1838,6 @@ impl<'ra, 'tcx> Resolver<'ra, 'tcx> {
let disambiguator = if ident.name == kw::Underscore {
self.underscore_disambiguator += 1;
self.underscore_disambiguator
} else if ident.name == kw::Empty {
self.empty_disambiguator += 1;
self.empty_disambiguator
} else {
0
};
Expand Down

0 comments on commit 12747f1

Please sign in to comment.