diff options
Diffstat (limited to 'crates/ra_syntax/src/ast')
-rw-r--r-- | crates/ra_syntax/src/ast/generated.rs | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/crates/ra_syntax/src/ast/generated.rs b/crates/ra_syntax/src/ast/generated.rs index 2fd146bf1..251d53bdf 100644 --- a/crates/ra_syntax/src/ast/generated.rs +++ b/crates/ra_syntax/src/ast/generated.rs | |||
@@ -2156,7 +2156,6 @@ pub enum PatKind<'a> { | |||
2156 | PlaceholderPat(&'a PlaceholderPat), | 2156 | PlaceholderPat(&'a PlaceholderPat), |
2157 | PathPat(&'a PathPat), | 2157 | PathPat(&'a PathPat), |
2158 | StructPat(&'a StructPat), | 2158 | StructPat(&'a StructPat), |
2159 | FieldPatList(&'a FieldPatList), | ||
2160 | TupleStructPat(&'a TupleStructPat), | 2159 | TupleStructPat(&'a TupleStructPat), |
2161 | TuplePat(&'a TuplePat), | 2160 | TuplePat(&'a TuplePat), |
2162 | SlicePat(&'a SlicePat), | 2161 | SlicePat(&'a SlicePat), |
@@ -2171,7 +2170,6 @@ impl AstNode for Pat { | |||
2171 | | PLACEHOLDER_PAT | 2170 | | PLACEHOLDER_PAT |
2172 | | PATH_PAT | 2171 | | PATH_PAT |
2173 | | STRUCT_PAT | 2172 | | STRUCT_PAT |
2174 | | FIELD_PAT_LIST | ||
2175 | | TUPLE_STRUCT_PAT | 2173 | | TUPLE_STRUCT_PAT |
2176 | | TUPLE_PAT | 2174 | | TUPLE_PAT |
2177 | | SLICE_PAT | 2175 | | SLICE_PAT |
@@ -2191,7 +2189,6 @@ impl Pat { | |||
2191 | PLACEHOLDER_PAT => PatKind::PlaceholderPat(PlaceholderPat::cast(&self.syntax).unwrap()), | 2189 | PLACEHOLDER_PAT => PatKind::PlaceholderPat(PlaceholderPat::cast(&self.syntax).unwrap()), |
2192 | PATH_PAT => PatKind::PathPat(PathPat::cast(&self.syntax).unwrap()), | 2190 | PATH_PAT => PatKind::PathPat(PathPat::cast(&self.syntax).unwrap()), |
2193 | STRUCT_PAT => PatKind::StructPat(StructPat::cast(&self.syntax).unwrap()), | 2191 | STRUCT_PAT => PatKind::StructPat(StructPat::cast(&self.syntax).unwrap()), |
2194 | FIELD_PAT_LIST => PatKind::FieldPatList(FieldPatList::cast(&self.syntax).unwrap()), | ||
2195 | TUPLE_STRUCT_PAT => PatKind::TupleStructPat(TupleStructPat::cast(&self.syntax).unwrap()), | 2192 | TUPLE_STRUCT_PAT => PatKind::TupleStructPat(TupleStructPat::cast(&self.syntax).unwrap()), |
2196 | TUPLE_PAT => PatKind::TuplePat(TuplePat::cast(&self.syntax).unwrap()), | 2193 | TUPLE_PAT => PatKind::TuplePat(TuplePat::cast(&self.syntax).unwrap()), |
2197 | SLICE_PAT => PatKind::SlicePat(SlicePat::cast(&self.syntax).unwrap()), | 2194 | SLICE_PAT => PatKind::SlicePat(SlicePat::cast(&self.syntax).unwrap()), |
@@ -3066,7 +3063,15 @@ impl AstNode for StructPat { | |||
3066 | } | 3063 | } |
3067 | 3064 | ||
3068 | 3065 | ||
3069 | impl StructPat {} | 3066 | impl StructPat { |
3067 | pub fn field_pat_list(&self) -> Option<&FieldPatList> { | ||
3068 | super::child_opt(self) | ||
3069 | } | ||
3070 | |||
3071 | pub fn path(&self) -> Option<&Path> { | ||
3072 | super::child_opt(self) | ||
3073 | } | ||
3074 | } | ||
3070 | 3075 | ||
3071 | // TokenTree | 3076 | // TokenTree |
3072 | #[derive(Debug, PartialEq, Eq, Hash)] | 3077 | #[derive(Debug, PartialEq, Eq, Hash)] |