3 Rustfmt is designed to be very configurable. You can create a TOML file called `rustfmt.toml` or `.rustfmt.toml`, place it in the project or any other parent directory and it will apply the options in that file.
5 A possible content of `rustfmt.toml` or `.rustfmt.toml` might look like this:
10 reorder_imported_names = true
13 # Configuration Options
15 Below you find a detailed visual guide on all the supported configuration options of rustfmt:
21 - **Default value**: `"Visual"`
22 - **Possible values**: `"Block"`, `"Visual"`
41 let lorem = vec!["ipsum",
52 Maximum width of an array literal before falling back to vertical formatting
54 - **Default value**: `60`
55 - **Possible values**: any positive integer
57 **Note:** A value of `0` results in [`array_layout`](#array_layout) being applied regardless of a line's width.
59 #### Lines shorter than `array_width`:
62 vec!["ipsum", "dolor", "sit", "amet", "consectetur", "adipiscing", "elit"];
65 #### Lines longer than `array_width`:
66 See [`array_layout`](#array_layout).
72 - **Default value**: `"Block"`
73 - **Possible values**: `"Block"`, `"Visual"`
90 let lorem = ipsum.dolor()
98 See also [`chain_one_line_max`](#chain_one_line_max).
100 ## `chain_one_line_max`
102 Maximum length of a chain to fit on a single line
104 - **Default value**: `60`
105 - **Possible values**: any positive integer
107 #### Lines shorter than `chain_one_line_max`:
109 let lorem = ipsum.dolor().sit().amet().consectetur().adipiscing().elit();
112 #### Lines longer than `chain_one_line_max`:
113 See [`chain_indent`](#chain_indent).
115 ## `chain_split_single_child`
117 Split a chain with a single child if its length exceeds [`chain_one_line_max`](#chain_one_line_max).
119 - **Default value**: `false`
120 - **Possible values**: `false`, `true`
125 let files = fs::read_dir("tests/coverage/source").expect("Couldn't read source dir");
131 let files = fs::read_dir("tests/coverage/source")
132 .expect("Couldn't read source dir");
135 See also [`chain_one_line_max`](#chain_one_line_max).
137 ## `closure_block_indent_threshold`
139 How many lines a closure must have before it is block indented. -1 means never use block indent.
141 - **Default value**: `7`
142 - **Possible values**: `-1`, or any positive integer
144 #### Closures shorter than `closure_block_indent_threshold`:
155 #### Closures longer than `closure_block_indent_threshold`:
163 println!("consectetur");
164 println!("adipiscing");
169 ## `combine_control_expr`
171 Combine control expressions with function calls.
173 - **Default value**: `true`
174 - **Possible values**: `true`, `false`
188 foo!(if let Some(..) = x {
201 foo!(while let Some(..) = x {
227 Maximum length of comments. No effect unless`wrap_comments = true`.
229 - **Default value**: `80`
230 - **Possible values**: any positive integer
232 **Note:** A value of `0` results in [`wrap_comments`](#wrap_comments) being applied regardless of a line's width.
234 #### Comments shorter than `comment_width`:
236 // Lorem ipsum dolor sit amet, consectetur adipiscing elit.
239 #### Comments longer than `comment_width`:
241 // Lorem ipsum dolor sit amet,
242 // consectetur adipiscing elit.
245 See also [`wrap_comments`](#wrap_comments).
247 ## `condense_wildcard_suffixes`
249 Replace strings of _ wildcards by a single .. in tuple patterns
251 - **Default value**: `false`
252 - **Possible values**: `true`, `false`
257 let (lorem, ipsum, _, _) = (1, 2, 3, 4);
263 let (lorem, ipsum, ..) = (1, 2, 3, 4);
266 ## `control_brace_style`
268 Brace style for control flow constructs
270 - **Default value**: `"AlwaysSameLine"`
271 - **Possible values**: `"AlwaysNextLine"`, `"AlwaysSameLine"`, `"ClosingNextLine"`
273 #### `"AlwaysNextLine"`:
286 #### `"AlwaysSameLine"`:
296 #### `"ClosingNextLine"`:
307 ## `disable_all_formatting`
309 Don't reformat anything
311 - **Default value**: `false`
312 - **Possible values**: `true`, `false`
314 ## `error_on_line_overflow`
316 Error if unable to get all lines within max_width
318 - **Default value**: `true`
319 - **Possible values**: `true`, `false`
321 See also [`max_width`](#max_width).
325 Argument density in functions
327 - **Default value**: `"Tall"`
328 - **Possible values**: `"Compressed"`, `"CompressedIfEmpty"`, `"Tall"`, `"Vertical"`
334 fn lorem(ipsum: Ipsum, dolor: Dolor, sit: Sit, amet: Amet);
336 fn lorem(ipsum: Ipsum, dolor: Dolor, sit: Sit, amet: Amet) {
340 fn lorem(ipsum: Ipsum, dolor: Dolor, sit: Sit, amet: Amet, consectetur: Consectetur,
341 adipiscing: Adipiscing, elit: Elit);
343 fn lorem(ipsum: Ipsum, dolor: Dolor, sit: Sit, amet: Amet, consectetur: Consectetur,
344 adipiscing: Adipiscing, elit: Elit) {
350 #### `"CompressedIfEmpty"`:
354 fn lorem(ipsum: Ipsum, dolor: Dolor, sit: Sit, amet: Amet);
356 fn lorem(ipsum: Ipsum, dolor: Dolor, sit: Sit, amet: Amet) {
360 fn lorem(ipsum: Ipsum, dolor: Dolor, sit: Sit, amet: Amet, consectetur: Consectetur,
361 adipiscing: Adipiscing, elit: Elit);
363 fn lorem(ipsum: Ipsum,
367 consectetur: onsectetur,
368 adipiscing: Adipiscing,
379 fn lorem(ipsum: Ipsum, dolor: Dolor, sit: Sit, amet: Amet);
381 fn lorem(ipsum: Ipsum, dolor: Dolor, sit: Sit, amet: Amet) {
385 fn lorem(ipsum: Ipsum,
389 consectetur: onsectetur,
390 adipiscing: Adipiscing,
393 fn lorem(ipsum: Ipsum,
397 consectetur: onsectetur,
398 adipiscing: Adipiscing,
409 fn lorem(ipsum: Ipsum,
414 fn lorem(ipsum: Ipsum,
421 fn lorem(ipsum: Ipsum,
425 consectetur: onsectetur,
426 adipiscing: Adipiscing,
429 fn lorem(ipsum: Ipsum,
433 consectetur: onsectetur,
434 adipiscing: Adipiscing,
443 Layout of function arguments and tuple structs
445 - **Default value**: `"Visual"`
446 - **Possible values**: `"Block"`, `"Visual"`
453 fn lorem(ipsum: usize) {}
473 fn lorem(ipsum: usize) {}
475 fn lorem(ipsum: usize,
486 ## `fn_args_paren_newline`
488 If function argument parenthesis goes on a newline
490 - **Default value**: `true`
491 - **Possible values**: `true`, `false`
501 -> DolorSitAmetConsecteturAdipiscingElitLoremIpsumDolorSitAmetConsecteturAdipiscingElit {
514 -> DolorSitAmetConsecteturAdipiscingElitLoremIpsumDolorSitAmetConsecteturAdipiscingElit {
521 Brace style for functions
523 - **Default value**: `"SameLineWhere"`
524 - **Possible values**: `"AlwaysNextLine"`, `"PreferSameLine"`, `"SameLineWhere"`
526 #### `"AlwaysNextLine"`:
534 fn lorem(ipsum: usize)
539 fn lorem<T>(ipsum: T)
540 where T: Add + Sub + Mul + Div
546 #### `"PreferSameLine"`:
553 fn lorem(ipsum: usize) {
557 fn lorem<T>(ipsum: T)
558 where T: Add + Sub + Mul + Div {
563 #### `"SameLineWhere"`:
570 fn lorem(ipsum: usize) {
574 fn lorem<T>(ipsum: T)
575 where T: Add + Sub + Mul + Div
583 Indentation for function calls, etc.
585 - **Default value**: `"Visual"`
586 - **Possible values**: `"Block"`, `"Visual"`
618 Maximum width of the args of a function call before falling back to vertical formatting
620 - **Default value**: `60`
621 - **Possible values**: any positive integer
623 **Note:** A value of `0` results in vertical formatting being applied regardless of a line's width.
625 #### Function call shorter than `fn_call_width`:
627 lorem("lorem", "ipsum", "dolor", "sit", "amet", "consectetur", "adipiscing", "elit");
630 #### Function call longer than `fn_call_width`:
632 See [`fn_call_style`](#fn_call_style).
634 ## `fn_empty_single_line`
636 Put empty-body functions on a single line
638 - **Default value**: `true`
639 - **Possible values**: `true`, `false`
654 See also [`control_brace_style`](#control_brace_style).
656 ## `fn_return_indent`
658 Location of return type in function declaration
660 - **Default value**: `"WithArgs"`
661 - **Possible values**: `"WithArgs"`, `"WithWhereClause"`
666 fn lorem(ipsum: Ipsum,
670 consectetur: Consectetur,
671 adipiscing: Adipiscing)
680 #### `"WithWhereClause"`:
683 fn lorem(ipsum: Ipsum,
687 consectetur: Consectetur,
688 adipiscing: Adipiscing)
699 Put single-expression functions on a single line
701 - **Default value**: `false`
702 - **Possible values**: `true`, `false`
707 fn lorem() -> usize {
711 fn lorem() -> usize {
720 fn lorem() -> usize { 42 }
722 fn lorem() -> usize {
728 See also [`control_brace_style`](#control_brace_style).
730 ## `force_explicit_abi`
732 Always print the abi for extern items
734 - **Default value**: `true`
735 - **Possible values**: `true`, `false`
737 **Note:** Non-"C" ABIs are always printed. If `false` then "C" is removed.
743 pub static lorem: c_int;
751 pub static lorem: c_int;
755 ## `force_format_strings`
757 Always format string literals
759 - **Default value**: `false`
760 - **Possible values**: `true`, `false`
762 See [`format_strings`](#format_strings).
764 See also [`max_width`](#max_width).
768 Format string literals where necessary
770 - **Default value**: `false`
771 - **Possible values**: `true`, `false`
776 let lorem = "ipsum dolor sit amet consectetur adipiscing elit lorem ipsum dolor sit";
783 "ipsum dolor sit amet consectetur \
784 adipiscing elit lorem ipsum dolor sit";
787 See also [`force_format_strings`](#force_format_strings), [`max_width`](#max_width).
791 Indentation of generics
793 - **Default value**: `"Visual"`
794 - **Possible values**: `"Block"`, `"Visual"`
804 Adipiscing: Eq = usize,
805 Consectetur: Eq = usize,
811 adipiscing: Adipiscing,
812 consectetur: Consectetur,
822 fn lorem<Ipsum: Eq = usize,
826 Adipiscing: Eq = usize,
827 Consectetur: Eq = usize,
833 adipiscing: Adipiscing,
834 consectetur: Consectetur,
843 Use tab characters for indentation, spaces for alignment
845 - **Default value**: `false`
846 - **Possible values**: `true`, `false`
851 fn lorem() -> usize {
852 42 // spaces before 42
859 fn lorem() -> usize {
864 See also: [`tab_spaces`](#tab_spaces).
866 ## `impl_empty_single_line`
868 Put empty-body implementations on a single line
870 - **Default value**: `true`
871 - **Possible values**: `true`, `false`
886 See also [`item_brace_style`](#item_brace_style).
888 ## `indent_match_arms`
890 Indent match arms instead of keeping them at the same indentation level as the match keyword
892 - **Default value**: `true`
893 - **Possible values**: `true`, `false`
917 See also: [`match_block_trailing_comma`](#match_block_trailing_comma), [`wrap_match_arms`](#wrap_match_arms).
919 ## `item_brace_style`
921 Brace style for structs and enums
923 - **Default value**: `"SameLineWhere"`
924 - **Possible values**: `"AlwaysNextLine"`, `"PreferSameLine"`, `"SameLineWhere"`
926 #### `"AlwaysNextLine"`:
941 #### `"PreferSameLine"`:
954 #### `"SameLineWhere"`:
968 ## `match_block_trailing_comma`
970 Put a trailing comma after a block based match arm (non-block arms are not affected)
972 - **Default value**: `false`
973 - **Possible values**: `true`, `false`
982 Lorem::Dolor => println!("dolor"),
993 Lorem::Dolor => println!("dolor"),
997 See also: [`indent_match_arms`](#indent_match_arms), [`trailing_comma`](#trailing_comma), [`wrap_match_arms`](#wrap_match_arms).
1001 Maximum width of each line
1003 - **Default value**: `100`
1004 - **Possible values**: any positive integer
1006 See also [`error_on_line_overflow`](#error_on_line_overflow).
1010 Unix or Windows line endings
1012 - **Default value**: `"Unix"`
1013 - **Possible values**: `"Native"`, `"Unix"`, `"Windows"`
1015 ## `normalize_comments`
1017 Convert /* */ comments to // comments where possible
1019 - **Default value**: `false`
1020 - **Possible values**: `true`, `false`
1026 fn dolor() -> usize {}
1029 fn adipiscing() -> usize {}
1036 fn dolor() -> usize {}
1039 fn adipiscing() -> usize {}
1042 ## `reorder_imported_names`
1044 Reorder lists of names in import statements alphabetically
1046 - **Default value**: `false`
1047 - **Possible values**: `true`, `false`
1052 use super::{lorem, ipsum, dolor, sit};
1058 use super::{dolor, ipsum, lorem, sit};
1061 See also [`reorder_imports`](#reorder_imports).
1063 ## `reorder_imports`
1065 Reorder import statements alphabetically
1067 - **Default value**: `false`
1068 - **Possible values**: `true`, `false`
1088 See also [`reorder_imported_names`](#reorder_imported_names), [`reorder_imports_in_group`](#reorder_imports_in_group).
1090 ## `reorder_imports_in_group`
1092 Reorder import statements in group
1094 - **Default value**: `false`
1095 - **Possible values**: `true`, `false`
1097 **Note:** This option takes effect only when [`reorder_imports`](#reorder_imports) is set to `true`.
1123 See also [`reorder_imports`](#reorder_imports).
1125 ## `single_line_if_else_max_width`
1127 Maximum line length for single line if-else expressions.
1129 - **Default value**: `50`
1130 - **Possible values**: any positive integer
1132 **Note:** A value of `0` results in if-else expressions being broken regardless of their line's width.
1134 #### Lines shorter than `single_line_if_else_max_width`:
1136 let lorem = if ipsum { dolor } else { sit };
1139 #### Lines longer than `single_line_if_else_max_width`:
1141 let lorem = if ipsum {
1148 See also: [`control_brace_style`](#control_brace_style).
1152 Don't reformat out of line modules
1154 - **Default value**: `false`
1155 - **Possible values**: `true`, `false`
1157 ## `space_after_bound_colon`
1159 Leave a space after the colon in a trait or lifetime bound
1161 - **Default value**: `true`
1162 - **Possible values**: `true`, `false`
1167 fn lorem<T:Eq>(t: T) {
1175 fn lorem<T: Eq>(t: T) {
1180 See also: [`space_before_bound`](#space_before_bound).
1182 ## `space_after_struct_lit_field_colon`
1184 Leave a space after the colon in a struct literal field
1186 - **Default value**: `true`
1187 - **Possible values**: `true`, `false`
1207 See also: [`space_before_struct_lit_field_colon`](#space_before_struct_lit_field_colon).
1209 ## `space_after_type_annotation_colon`
1211 Leave a space after the colon in a type annotation
1213 - **Default value**: `true`
1214 - **Possible values**: `true`, `false`
1219 fn lorem<T: Eq>(t:T) {
1220 let ipsum:Dolor = sit;
1227 fn lorem<T: Eq>(t: T) {
1228 let ipsum: Dolor = sit;
1232 See also: [`space_before_type_annotation`](#space_before_type_annotation).
1234 ## `space_before_bound`
1236 Leave a space before the colon in a trait or lifetime bound
1238 - **Default value**: `false`
1239 - **Possible values**: `true`, `false`
1244 fn lorem<T: Eq>(t: T) {
1245 let ipsum: Dolor = sit;
1252 fn lorem<T : Eq>(t: T) {
1253 let ipsum: Dolor = sit;
1257 See also: [`space_after_bound_colon`](#space_after_bound_colon).
1259 ## `space_before_struct_lit_field_colon`
1261 Leave a space before the colon in a struct literal field
1263 - **Default value**: `true`
1264 - **Possible values**: `true`, `false`
1284 See also: [`space_after_struct_lit_field_colon`](#space_after_struct_lit_field_colon).
1286 ## `space_before_type_annotation`
1288 Leave a space before the colon in a type annotation
1290 - **Default value**: `false`
1291 - **Possible values**: `true`, `false`
1296 fn lorem<T: Eq>(t: T) {
1297 let ipsum: Dolor = sit;
1304 fn lorem<T: Eq>(t : T) {
1305 let ipsum : Dolor = sit;
1309 See also: [`space_after_type_annotation_colon`](#space_after_type_annotation_colon).
1311 ## `spaces_around_ranges`
1313 Put spaces around the .. and ... range operators
1315 - **Default value**: `false`
1316 - **Possible values**: `true`, `false`
1327 let lorem = 0 .. 10;
1330 ## `spaces_within_angle_brackets`
1332 Put spaces within non-empty generic arguments
1334 - **Default value**: `false`
1335 - **Possible values**: `true`, `false`
1340 fn lorem<T: Eq>(t: T) {
1348 fn lorem< T: Eq >(t: T) {
1353 See also: [`spaces_within_parens`](#spaces_within_parens), [`spaces_within_square_brackets`](#spaces_within_square_brackets).
1355 ## `spaces_within_parens`
1357 Put spaces within non-empty parentheses
1359 - **Default value**: `false`
1360 - **Possible values**: `true`, `false`
1365 fn lorem<T: Eq>(t: T) {
1366 let lorem = (ipsum, dolor);
1373 fn lorem<T: Eq>( t: T ) {
1374 let lorem = ( ipsum, dolor );
1378 See also: [`spaces_within_angle_brackets`](#spaces_within_angle_brackets), [`spaces_within_square_brackets`](#spaces_within_square_brackets).
1380 ## `spaces_within_square_brackets`
1382 Put spaces within non-empty square brackets
1384 - **Default value**: `false`
1385 - **Possible values**: `true`, `false`
1390 let lorem: [usize; 2] = [ipsum, dolor];
1396 let lorem: [ usize; 2 ] = [ ipsum, dolor ];
1399 See also: [`spaces_within_parens`](#spaces_within_parens), [`spaces_within_angle_brackets`](#spaces_within_angle_brackets).
1401 ## `struct_lit_multiline_style`
1403 Multiline style on literal structs
1405 - **Default value**: `"PreferSingle"`
1406 - **Possible values**: `"ForceMulti"`, `"PreferSingle"`
1408 #### `"ForceMulti"`:
1417 #### `"PreferSingle"`:
1420 let lorem = Lorem { ipsum: dolor, sit: amet };
1423 See also: [`struct_lit_style`](#struct_lit_style), [`struct_lit_width`](#struct_lit_width).
1425 ## `struct_lit_style`
1427 Style of struct definition
1429 - **Default value**: `"Block"`
1430 - **Possible values**: `"Block"`, `"Visual"`
1444 let lorem = Lorem { ipsum: dolor,
1448 See also: [`struct_lit_multiline_style`](#struct_lit_multiline_style), [`struct_lit_style`](#struct_lit_style).
1450 ## `struct_lit_width`
1452 Maximum width in the body of a struct lit before falling back to vertical formatting
1454 - **Default value**: `18`
1455 - **Possible values**: any positive integer
1457 **Note:** A value of `0` results in vertical formatting being applied regardless of a line's width.
1459 #### Lines shorter than `struct_lit_width`:
1461 let lorem = Lorem { ipsum: dolor, sit: amet };
1464 #### Lines longer than `struct_lit_width`:
1465 See [`struct_lit_style`](#struct_lit_style).
1467 See also: [`struct_lit_multiline_style`](#struct_lit_multiline_style), [`struct_lit_style`](#struct_lit_style).
1469 ## `struct_variant_width`
1471 Maximum width in the body of a struct variant before falling back to vertical formatting
1473 - **Default value**: `35`
1474 - **Possible values**: any positive integer
1476 **Note:** A value of `0` results in vertical formatting being applied regardless of a line's width.
1478 #### Struct variants shorter than `struct_variant_width`:
1483 Sit { amet: Consectetur, adipiscing: Elit },
1487 #### Struct variants longer than `struct_variant_width`:
1501 Number of spaces per tab
1503 - **Default value**: `4`
1504 - **Possible values**: any positive integer
1510 let ipsum = dolor();
1512 "amet consectetur adipiscing elit."
1521 let ipsum = dolor();
1523 "amet consectetur adipiscing elit."
1528 See also: [`hard_tabs`](#hard_tabs).
1530 ## `take_source_hints`
1532 Retain some formatting characteristics from the source code
1534 - **Default value**: `false`
1535 - **Possible values**: `true`, `false`
1542 .dolor(|| { sit.amet().consectetur().adipiscing().elit(); });
1558 Note: This only applies if the call chain within the inner closure had already been formatted on separate lines before running rustfmt.
1562 How to handle trailing commas for lists
1564 - **Default value**: `"Vertical"`
1565 - **Possible values**: `"Always"`, `"Never"`, `"Vertical"`
1570 let Lorem { ipsum, dolor, sit, } = amet;
1584 let Lorem { ipsum, dolor, sit } = amet;
1598 let Lorem { ipsum, dolor, sit } = amet;
1609 See also: [`match_block_trailing_comma`](#match_block_trailing_comma).
1611 ## `type_punctuation_density`
1613 Determines if `+` or `=` are wrapped in spaces in the punctuation of types
1615 - **Default value**: `"Wide"`
1616 - **Possible values**: `"Compressed"`, `"Wide"`
1618 #### `"Compressed"`:
1621 fn lorem<Ipsum: Dolor+Sit=Amet>() {
1629 fn lorem<Ipsum: Dolor + Sit = Amet>() {
1634 ## `use_try_shorthand`
1636 Replace uses of the try! macro by the ? shorthand
1638 - **Default value**: `false`
1639 - **Possible values**: `true`, `false`
1644 let lorem = try!(ipsum.map(|dolor|dolor.sit()));
1650 let lorem = ipsum.map(|dolor| dolor.sit())?;
1655 Density of a where clause
1657 - **Default value**: `"CompressedIfEmpty"`
1658 - **Possible values**: `"Compressed"`, `"CompressedIfEmpty"`, `"Tall"`, `"Vertical"`
1660 #### `"Compressed"`:
1664 fn ipsum<Dolor>(dolor: Dolor) -> Sit where Dolor: Eq;
1666 fn ipsum<Dolor>(dolor: Dolor) -> Sit where Dolor: Eq {
1672 #### `"CompressedIfEmpty"`:
1676 fn ipsum<Dolor>(dolor: Dolor) -> Sit where Dolor: Eq;
1678 fn ipsum<Dolor>(dolor: Dolor) -> Sit
1690 fn ipsum<Dolor>(dolor: Dolor) -> Sit
1693 fn ipsum<Dolor>(dolor: Dolor) -> Sit
1701 **Note:** `where_density = "Tall"` currently produces the same output as `where_density = "Vertical"`.
1707 fn ipsum<Dolor>(dolor: Dolor) -> Sit
1710 fn ipsum<Dolor>(dolor: Dolor) -> Sit
1718 **Note:** `where_density = "Vertical"` currently produces the same output as `where_density = "Tall"`.
1720 See also: [`where_layout`](#where_layout), [`where_pred_indent`](#where_pred_indent), [`where_style`](#where_style).
1724 Element layout inside a where clause
1726 - **Default value**: `"Vertical"`
1727 - **Possible values**: `"Horizontal"`, `"HorizontalVertical"`, `"Mixed"`, `"Vertical"`
1729 #### `"Horizontal"`:
1732 fn lorem<Ipsum, Dolor>(ipsum: Ipsum, dolor: Dolor)
1733 where Ipsum: IpsumDolorSitAmet, Dolor: DolorSitAmetConsectetur
1738 fn lorem<Ipsum, Dolor, Sit, Amet>(ipsum: Ipsum, dolor: Dolor, sit: Sit, amet: Amet)
1739 where Ipsum: IpsumDolorSitAmet, Dolor: DolorSitAmetConsectetur, Sit: SitAmetConsecteturAdipiscing, Amet: AmetConsecteturAdipiscingElit
1745 #### `"HorizontalVertical"`:
1748 fn lorem<Ipsum, Dolor>(ipsum: Ipsum, dolor: Dolor)
1749 where Ipsum: IpsumDolorSitAmet, Dolor: DolorSitAmetConsectetur
1754 fn lorem<Ipsum, Dolor, Sit, Amet>(ipsum: Ipsum, dolor: Dolor, sit: Sit, amet: Amet)
1755 where Ipsum: IpsumDolorSitAmet,
1756 Dolor: DolorSitAmetConsectetur,
1757 Sit: SitAmetConsecteturAdipiscing,
1758 Amet: AmetConsecteturAdipiscingElit
1767 fn lorem<Ipsum, Dolor>(ipsum: Ipsum, dolor: Dolor)
1768 where Ipsum: IpsumDolorSitAmet, Dolor: DolorSitAmetConsectetur
1773 fn lorem<Ipsum, Dolor, Sit, Amet>(ipsum: Ipsum, dolor: Dolor, sit: Sit, amet: Amet)
1774 where Ipsum: IpsumDolorSitAmet, Dolor: DolorSitAmetConsectetur,
1775 Sit: SitAmetConsecteturAdipiscing, Amet: AmetConsecteturAdipiscingElit
1784 fn lorem<Ipsum, Dolor>(ipsum: Ipsum, dolor: Dolor)
1785 where Ipsum: IpsumDolorSitAmet,
1786 Dolor: DolorSitAmetConsectetur
1791 fn lorem<Ipsum, Dolor, Sit, Amet>(ipsum: Ipsum, dolor: Dolor, sit: Sit, amet: Amet)
1792 where Ipsum: IpsumDolorSitAmet,
1793 Dolor: DolorSitAmetConsectetur,
1794 Sit: SitAmetConsecteturAdipiscing,
1795 Amet: AmetConsecteturAdipiscingElit
1801 See also: [`where_density`](#where_density), [`where_pred_indent`](#where_pred_indent), [`where_style`](#where_style).
1803 ## `where_pred_indent`
1805 Indentation style of a where predicate
1807 - **Default value**: `"Visual"`
1808 - **Possible values**: `"Block"`, `"Visual"`
1813 fn lorem<Ipsum, Dolor, Sit, Amet>() -> T
1826 fn lorem<Ipsum, Dolor, Sit, Amet>() -> T
1836 See also: [`where_density`](#where_density), [`where_layout`](#where_layout), [`where_style`](#where_style).
1840 Overall strategy for where clauses
1842 - **Default value**: `"Default"`
1843 - **Possible values**: `"Default"`, `"Rfc"`
1848 fn lorem<Ipsum, Dolor, Sit, Amet>() -> T
1861 fn lorem<Ipsum, Dolor, Sit, Amet>() -> T
1872 See also: [`where_density`](#where_density), [`where_layout`](#where_layout), [`where_pred_indent`](#where_pred_indent).
1876 Break comments to fit on the line
1878 - **Default value**: `false`
1879 - **Possible values**: `true`, `false`
1884 // Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
1890 // Lorem ipsum dolor sit amet, consectetur adipiscing elit,
1891 // sed do eiusmod tempor incididunt ut labore et dolore
1892 // magna aliqua. Ut enim ad minim veniam, quis nostrud
1893 // exercitation ullamco laboris nisi ut aliquip ex ea
1894 // commodo consequat.
1897 ## `wrap_match_arms`
1899 Wrap multiline match arms in blocks
1901 - **Default value**: `true`
1902 - **Possible values**: `true`, `false`
1910 println!("{}", ipsum);
1924 println!("{}", ipsum);
1926 false => println!("{}", sit),
1930 See also: [`indent_match_arms`](#indent_match_arms), [`match_block_trailing_comma`](#match_block_trailing_comma).
1934 What Write Mode to use when none is supplied: Replace, Overwrite, Display, Diff, Coverage
1936 - **Default value**: `"Replace"`
1937 - **Possible values**: `"Checkstyle"`, `"Coverage"`, `"Diff"`, `"Display"`, `"Overwrite"`, `"Plain"`, `"Replace"`