Skip to content

Commit 41a7c6e

Browse files
committed
rustfmt: Set use_small_heuristics to Max
As we do in `rust-bitcoin` set the `use_small_heuristics` option to max, this sets all granular width options to the same as the max value (100). Only change the `rustfmt` config file, we will run the formatter as a separate patch.
1 parent ee4564e commit 41a7c6e

File tree

1 file changed

+13
-9
lines changed

1 file changed

+13
-9
lines changed

rustfmt.toml

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,20 @@
1-
max_width = 100
21
hard_tabs = false
32
tab_spaces = 4
43
newline_style = "Auto"
54
indent_style = "Block"
6-
use_small_heuristics = "Default"
7-
fn_call_width = 60
8-
attr_fn_like_width = 70
9-
struct_lit_width = 18
10-
struct_variant_width = 35
11-
array_width = 60
12-
chain_width = 60
13-
single_line_if_else_max_width = 50
5+
6+
max_width = 100 # This is number of characters.
7+
# `use_small_heuristics` is ignored if the granular width config values are explicitly set.
8+
use_small_heuristics = "Max" # "Max" == All granular width settings same as `max_width`.
9+
# # Granular width configuration settings. These are percentages of `max_width`.
10+
# fn_call_width = 60
11+
# attr_fn_like_width = 70
12+
# struct_lit_width = 18
13+
# struct_variant_width = 35
14+
# array_width = 60
15+
# chain_width = 60
16+
# single_line_if_else_max_width = 50
17+
1418
wrap_comments = false
1519
format_code_in_doc_comments = false
1620
comment_width = 80

0 commit comments

Comments
 (0)