File tree Expand file tree Collapse file tree 2 files changed +8
-7
lines changed
Expand file tree Collapse file tree 2 files changed +8
-7
lines changed Original file line number Diff line number Diff line change @@ -92,7 +92,7 @@ create_config! {
9292 the same line with the pattern of arms";
9393 force_multiline_blocks: bool , false , false ,
9494 "Force multiline closure bodies and match arms to be wrapped in a block" ;
95- fn_args_layout: ItemsLayout , ItemsLayout :: Tall , true ,
95+ fn_args_layout: Density , Density :: Tall , true ,
9696 "Control the layout of arguments in a function" ;
9797 brace_style: BraceStyle , BraceStyle :: SameLineWhere , false , "Brace style for items" ;
9898 control_brace_style: ControlBraceStyle , ControlBraceStyle :: AlwaysSameLine , false ,
Original file line number Diff line number Diff line change @@ -58,7 +58,8 @@ pub enum IndentStyle {
5858
5959#[ config_type]
6060/// How to place a list-like items.
61- pub enum ItemsLayout {
61+ /// FIXME: Issue-3581: this should be renamed to ItemsLayout when publishing 2.0
62+ pub enum Density {
6263 /// Fit as much on one line as possible.
6364 Compressed ,
6465 /// Items are placed horizontally if sufficient space, vertically otherwise.
@@ -87,13 +88,13 @@ pub enum Heuristics {
8788 Default ,
8889}
8990
90- impl ItemsLayout {
91+ impl Density {
9192 pub fn to_list_tactic ( self , len : usize ) -> ListTactic {
9293 match self {
93- ItemsLayout :: Compressed => ListTactic :: Mixed ,
94- ItemsLayout :: Tall => ListTactic :: HorizontalVertical ,
95- ItemsLayout :: Vertical if len == 1 => ListTactic :: Horizontal ,
96- ItemsLayout :: Vertical => ListTactic :: Vertical ,
94+ Density :: Compressed => ListTactic :: Mixed ,
95+ Density :: Tall => ListTactic :: HorizontalVertical ,
96+ Density :: Vertical if len == 1 => ListTactic :: Horizontal ,
97+ Density :: Vertical => ListTactic :: Vertical ,
9798 }
9899 }
99100}
You can’t perform that action at this time.
0 commit comments