This repository was archived by the owner on May 28, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 3 files changed +17
-2
lines changed Expand file tree Collapse file tree 3 files changed +17
-2
lines changed Original file line number Diff line number Diff line change @@ -328,8 +328,9 @@ where
328
328
Shape :: legacy ( budget, offset)
329
329
} ;
330
330
331
+ let is_inputs_empty = inputs. len ( ) == 0 ;
331
332
let list_lo = context. snippet_provider . span_after ( span, "(" ) ;
332
- let ( list_str, tactic) = if inputs . len ( ) == 0 {
333
+ let ( list_str, tactic) = if is_inputs_empty {
333
334
let tactic = get_tactics ( & [ ] , & output, shape) ;
334
335
let list_hi = context. snippet_provider . span_before ( span, ")" ) ;
335
336
let comment = context
@@ -377,7 +378,10 @@ where
377
378
( write_list ( & item_vec, & fmt) ?, tactic)
378
379
} ;
379
380
380
- let args = if tactic == DefinitiveListTactic :: Horizontal || !context. use_block_indent ( ) {
381
+ let args = if tactic == DefinitiveListTactic :: Horizontal
382
+ || !context. use_block_indent ( )
383
+ || is_inputs_empty
384
+ {
381
385
format ! ( "({})" , list_str)
382
386
} else {
383
387
format ! (
Original file line number Diff line number Diff line change
1
+ fn f ( ) -> Box <
2
+ dyn FnMut ( ) -> Thing < WithType = LongItemName , Error = LONGLONGLONGLONGLONGONGEvenLongerErrorNameLongerLonger > ,
3
+ > {
4
+ }
Original file line number Diff line number Diff line change
1
+ fn f ( ) -> Box <
2
+ dyn FnMut ( ) -> Thing <
3
+ WithType = LongItemName ,
4
+ Error = LONGLONGLONGLONGLONGONGEvenLongerErrorNameLongerLonger ,
5
+ > ,
6
+ > {
7
+ }
You can’t perform that action at this time.
0 commit comments