File tree 1 file changed +4
-4
lines changed
1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -1142,8 +1142,8 @@ pub type ExplicitSelf = Spanned<SelfKind>;
1142
1142
1143
1143
impl Arg {
1144
1144
pub fn to_self ( & self ) -> Option < ExplicitSelf > {
1145
- if let PatKind :: Ident ( BindByValue ( mutbl) , ident , _) = self . pat . node {
1146
- if ident . node . unhygienic_name == keywords:: SelfValue . name ( ) {
1145
+ if let PatKind :: Ident ( BindByValue ( mutbl) , name , _) = self . pat . node {
1146
+ if name . node . unhygienize ( ) == keywords:: SelfValue . name ( ) {
1147
1147
return match self . ty . node {
1148
1148
TyInfer => Some ( respan ( self . pat . span , SelfKind :: Value ( mutbl) ) ) ,
1149
1149
TyRptr ( lt, MutTy { ref ty, mutbl} ) if ty. node == TyInfer => {
@@ -1158,8 +1158,8 @@ impl Arg {
1158
1158
}
1159
1159
1160
1160
pub fn is_self ( & self ) -> bool {
1161
- if let PatKind :: Ident ( _, ident , _) = self . pat . node {
1162
- ident . node . unhygienic_name == keywords:: SelfValue . name ( )
1161
+ if let PatKind :: Ident ( _, name , _) = self . pat . node {
1162
+ name . node . unhygienize ( ) == keywords:: SelfValue . name ( )
1163
1163
} else {
1164
1164
false
1165
1165
}
You can’t perform that action at this time.
0 commit comments