diff options
| author | Michael Goulet <michael@errs.io> | 2024-09-29 22:17:30 -0400 |
|---|---|---|
| committer | Michael Goulet <michael@errs.io> | 2024-10-01 13:55:46 -0400 |
| commit | 40465d2449f3d9a36c86b94885f58ed3ee2a99f0 (patch) | |
| tree | a98bcd2bbf0fe57748eba20e2c90eaf96c4471d8 /compiler/rustc_ast/src/ast.rs | |
| parent | e3a0da18633a8cfb5263bb975747352690b01fcf (diff) | |
| download | rust-40465d2449f3d9a36c86b94885f58ed3ee2a99f0.tar.gz rust-40465d2449f3d9a36c86b94885f58ed3ee2a99f0.zip | |
Remove anon struct and union types
Diffstat (limited to 'compiler/rustc_ast/src/ast.rs')
| -rw-r--r-- | compiler/rustc_ast/src/ast.rs | 8 |
1 files changed, 0 insertions, 8 deletions
diff --git a/compiler/rustc_ast/src/ast.rs b/compiler/rustc_ast/src/ast.rs index 37f429cce44..4a92cc881fa 100644 --- a/compiler/rustc_ast/src/ast.rs +++ b/compiler/rustc_ast/src/ast.rs @@ -2167,10 +2167,6 @@ pub enum TyKind { Never, /// A tuple (`(A, B, C, D,...)`). Tup(ThinVec<P<Ty>>), - /// An anonymous struct type i.e. `struct { foo: Type }`. - AnonStruct(NodeId, ThinVec<FieldDef>), - /// An anonymous union type i.e. `union { bar: Type }`. - AnonUnion(NodeId, ThinVec<FieldDef>), /// A path (`module::module::...::Type`), optionally /// "qualified", e.g., `<Vec<T> as SomeTrait>::SomeType`. /// @@ -2227,10 +2223,6 @@ impl TyKind { None } } - - pub fn is_anon_adt(&self) -> bool { - matches!(self, TyKind::AnonStruct(..) | TyKind::AnonUnion(..)) - } } /// Syntax used to declare a trait object. |
