@@ -172,11 +172,10 @@ where
172
172
173
173
let limit = match tactic {
174
174
_ if pre_line_comments => return DefinitiveListTactic :: Vertical ,
175
- ListTactic :: Mixed => return DefinitiveListTactic :: Mixed ,
176
175
ListTactic :: Horizontal => return DefinitiveListTactic :: Horizontal ,
177
176
ListTactic :: Vertical => return DefinitiveListTactic :: Vertical ,
178
177
ListTactic :: LimitedHorizontalVertical ( limit) => :: std:: cmp:: min ( width, limit) ,
179
- ListTactic :: HorizontalVertical => width,
178
+ ListTactic :: Mixed | ListTactic :: HorizontalVertical => width,
180
179
} ;
181
180
182
181
let ( sep_count, total_width) = calculate_width ( items. clone ( ) ) ;
@@ -188,7 +187,10 @@ where
188
187
{
189
188
DefinitiveListTactic :: Horizontal
190
189
} else {
191
- DefinitiveListTactic :: Vertical
190
+ match tactic {
191
+ ListTactic :: Mixed => DefinitiveListTactic :: Mixed ,
192
+ _ => DefinitiveListTactic :: Vertical ,
193
+ }
192
194
}
193
195
}
194
196
@@ -276,8 +278,7 @@ where
276
278
277
279
if last && formatting. ends_with_newline {
278
280
match formatting. trailing_separator {
279
- SeparatorTactic :: Always => separate = true ,
280
- SeparatorTactic :: Vertical if result. contains ( '\n' ) => separate = true ,
281
+ SeparatorTactic :: Always | SeparatorTactic :: Vertical => separate = true ,
281
282
_ => ( ) ,
282
283
}
283
284
}
0 commit comments