Remove more traces of anonymous ADTs

This commit is contained in:
Michael Goulet
2024-12-10 19:50:40 +00:00
parent 33c245b9e9
commit 916d279236
12 changed files with 5 additions and 38 deletions

View File

@@ -289,8 +289,6 @@ pub enum DefPathData {
/// An existential `impl Trait` type node.
/// Argument position `impl Trait` have a `TypeNs` with their pretty-printed name.
OpaqueTy,
/// An anonymous struct or union type i.e. `struct { foo: Type }` or `union { bar: Type }`
AnonAdt,
}
impl Definitions {
@@ -415,7 +413,7 @@ impl DefPathData {
TypeNs(name) | ValueNs(name) | MacroNs(name) | LifetimeNs(name) => Some(name),
Impl | ForeignMod | CrateRoot | Use | GlobalAsm | Closure | Ctor | AnonConst
| OpaqueTy | AnonAdt => None,
| OpaqueTy => None,
}
}
@@ -438,7 +436,6 @@ impl DefPathData {
Ctor => DefPathDataName::Anon { namespace: sym::constructor },
AnonConst => DefPathDataName::Anon { namespace: sym::constant },
OpaqueTy => DefPathDataName::Anon { namespace: sym::opaque },
AnonAdt => DefPathDataName::Anon { namespace: sym::anon_adt },
}
}
}