@@ -1175,10 +1175,10 @@ impl PathPat {
11751175 pub fn path ( & self ) -> Option < Path > { support:: child ( & self . syntax ) }
11761176}
11771177#[ derive( Debug , Clone , PartialEq , Eq , Hash ) ]
1178- pub struct PlaceholderPat {
1178+ pub struct WildcardPat {
11791179 pub ( crate ) syntax : SyntaxNode ,
11801180}
1181- impl PlaceholderPat {
1181+ impl WildcardPat {
11821182 pub fn underscore_token ( & self ) -> Option < SyntaxToken > { support:: token ( & self . syntax , T ! [ _] ) }
11831183}
11841184#[ derive( Debug , Clone , PartialEq , Eq , Hash ) ]
@@ -1343,7 +1343,7 @@ pub enum Pat {
13431343 OrPat ( OrPat ) ,
13441344 ParenPat ( ParenPat ) ,
13451345 PathPat ( PathPat ) ,
1346- PlaceholderPat ( PlaceholderPat ) ,
1346+ WildcardPat ( WildcardPat ) ,
13471347 RangePat ( RangePat ) ,
13481348 RecordPat ( RecordPat ) ,
13491349 RefPat ( RefPat ) ,
@@ -2644,8 +2644,8 @@ impl AstNode for PathPat {
26442644 }
26452645 fn syntax ( & self ) -> & SyntaxNode { & self . syntax }
26462646}
2647- impl AstNode for PlaceholderPat {
2648- fn can_cast ( kind : SyntaxKind ) -> bool { kind == PLACEHOLDER_PAT }
2647+ impl AstNode for WildcardPat {
2648+ fn can_cast ( kind : SyntaxKind ) -> bool { kind == WILDCARD_PAT }
26492649 fn cast ( syntax : SyntaxNode ) -> Option < Self > {
26502650 if Self :: can_cast ( syntax. kind ( ) ) {
26512651 Some ( Self { syntax } )
@@ -3160,8 +3160,8 @@ impl From<ParenPat> for Pat {
31603160impl From < PathPat > for Pat {
31613161 fn from ( node : PathPat ) -> Pat { Pat :: PathPat ( node) }
31623162}
3163- impl From < PlaceholderPat > for Pat {
3164- fn from ( node : PlaceholderPat ) -> Pat { Pat :: PlaceholderPat ( node) }
3163+ impl From < WildcardPat > for Pat {
3164+ fn from ( node : WildcardPat ) -> Pat { Pat :: WildcardPat ( node) }
31653165}
31663166impl From < RangePat > for Pat {
31673167 fn from ( node : RangePat ) -> Pat { Pat :: RangePat ( node) }
@@ -3185,7 +3185,7 @@ impl AstNode for Pat {
31853185 fn can_cast ( kind : SyntaxKind ) -> bool {
31863186 match kind {
31873187 BIND_PAT | BOX_PAT | DOT_DOT_PAT | LITERAL_PAT | MACRO_PAT | OR_PAT | PAREN_PAT
3188- | PATH_PAT | PLACEHOLDER_PAT | RANGE_PAT | RECORD_PAT | REF_PAT | SLICE_PAT
3188+ | PATH_PAT | WILDCARD_PAT | RANGE_PAT | RECORD_PAT | REF_PAT | SLICE_PAT
31893189 | TUPLE_PAT | TUPLE_STRUCT_PAT => true ,
31903190 _ => false ,
31913191 }
@@ -3200,7 +3200,7 @@ impl AstNode for Pat {
32003200 OR_PAT => Pat :: OrPat ( OrPat { syntax } ) ,
32013201 PAREN_PAT => Pat :: ParenPat ( ParenPat { syntax } ) ,
32023202 PATH_PAT => Pat :: PathPat ( PathPat { syntax } ) ,
3203- PLACEHOLDER_PAT => Pat :: PlaceholderPat ( PlaceholderPat { syntax } ) ,
3203+ WILDCARD_PAT => Pat :: WildcardPat ( WildcardPat { syntax } ) ,
32043204 RANGE_PAT => Pat :: RangePat ( RangePat { syntax } ) ,
32053205 RECORD_PAT => Pat :: RecordPat ( RecordPat { syntax } ) ,
32063206 REF_PAT => Pat :: RefPat ( RefPat { syntax } ) ,
@@ -3221,7 +3221,7 @@ impl AstNode for Pat {
32213221 Pat :: OrPat ( it) => & it. syntax ,
32223222 Pat :: ParenPat ( it) => & it. syntax ,
32233223 Pat :: PathPat ( it) => & it. syntax ,
3224- Pat :: PlaceholderPat ( it) => & it. syntax ,
3224+ Pat :: WildcardPat ( it) => & it. syntax ,
32253225 Pat :: RangePat ( it) => & it. syntax ,
32263226 Pat :: RecordPat ( it) => & it. syntax ,
32273227 Pat :: RefPat ( it) => & it. syntax ,
@@ -4021,7 +4021,7 @@ impl std::fmt::Display for PathPat {
40214021 std:: fmt:: Display :: fmt ( self . syntax ( ) , f)
40224022 }
40234023}
4024- impl std:: fmt:: Display for PlaceholderPat {
4024+ impl std:: fmt:: Display for WildcardPat {
40254025 fn fmt ( & self , f : & mut std:: fmt:: Formatter < ' _ > ) -> std:: fmt:: Result {
40264026 std:: fmt:: Display :: fmt ( self . syntax ( ) , f)
40274027 }
0 commit comments