@@ -119,7 +119,7 @@ enum ChainItemKind {
119
119
Vec < ptr:: P < ast:: Expr > > ,
120
120
) ,
121
121
StructField ( symbol:: Ident ) ,
122
- TupleField ( symbol:: Ident , bool ) ,
122
+ TupleField ( symbol:: Ident ) ,
123
123
Await ,
124
124
Comment ( String , CommentPosition ) ,
125
125
}
@@ -171,7 +171,7 @@ impl ChainItemKind {
171
171
}
172
172
ast:: ExprKind :: Field ( ref nested, field) => {
173
173
let kind = if Self :: is_tup_field_access ( expr) {
174
- ChainItemKind :: TupleField ( field, Self :: is_tup_field_access ( nested ) )
174
+ ChainItemKind :: TupleField ( field)
175
175
} else {
176
176
ChainItemKind :: StructField ( field)
177
177
} ;
@@ -199,12 +199,9 @@ impl Rewrite for ChainItem {
199
199
ChainItemKind :: MethodCall ( ref segment, ref types, ref exprs) => {
200
200
Self :: rewrite_method_call ( segment. ident , types, exprs, self . span , context, shape) ?
201
201
}
202
- ChainItemKind :: StructField ( ident) => format ! ( ".{}" , rewrite_ident( context, ident) ) ,
203
- ChainItemKind :: TupleField ( ident, nested) => format ! (
204
- "{}.{}" ,
205
- if nested { " " } else { "" } ,
206
- rewrite_ident( context, ident)
207
- ) ,
202
+ ChainItemKind :: StructField ( ident) | ChainItemKind :: TupleField ( ident) => {
203
+ format ! ( ".{}" , rewrite_ident( context, ident) )
204
+ }
208
205
ChainItemKind :: Await => ".await" . to_owned ( ) ,
209
206
ChainItemKind :: Comment ( ref comment, _) => {
210
207
rewrite_comment ( comment, false , shape, context. config ) ?
0 commit comments