-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrustfmt.toml
executable file
·37 lines (28 loc) · 1.56 KB
/
rustfmt.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
unstable_features = true # Default: false
edition = "2024" # Default: "2015"
style_edition = "2024"
newline_style = "Unix" # Default: "Auto"
#max_width = 80 # Default: 100
#use_small_heuristics = "Max" # Default: "Default"; with "Max", each granular width setting is set to the same value as max_width, as opposed to a ratio of max_width.
#indent_style = "Visual" # Default: "Block"
## Imports
imports_granularity = "Item" # Default: Preserve; consider "Crate" or "Module" as well
# imports_layout = "Vertical" # Item layout inside a imports block; default: "Mixed"
group_imports = "StdExternalCrate" # Default: "Preserve"; "StdExternalCrate" creates three groups for: std, core and alloc; external crates; and self, super and crate imports.
## Comments
#comment_width = 70 # Default: 80
wrap_comments = true # Default: false
normalize_comments = true # Convert /* */ comments to // comments where possible; default: false
normalize_doc_attributes = true # Convert #![doc] and #[doc] attributes to //! and /// doc comments. Default: false
format_code_in_doc_comments = true # Default: false
## Functions
#fn_params_layout = "Compressed" # Control the layout of parameters in function signatures. default: "Tall"
## Impl
reorder_impl_items = true # Reorder impl items. type and const are put first, then macros and methods. Default: false
## Structs
use_field_init_shorthand = true # Use field initialize shorthand if possible. Default: false
## Macros
use_try_shorthand = true # Replace uses of the try! macro by the ? shorthand. Default: false
## Ignore specific files
ignore = [
]