aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorcypherpunks <cypherpunks@torproject.org>2018-08-04 01:04:15 +0000
committerNick Mathewson <nickm@torproject.org>2018-08-16 08:42:57 -0400
commitceac10fc3d664a5d7ee910965a5e0d15ea67adb1 (patch)
tree1e72d810245f2e24e83f9795853afa7726cc4bb5
parentfef2ba2267af831ff8579f8f63a898135954f44d (diff)
downloadtor-ceac10fc3d664a5d7ee910965a5e0d15ea67adb1.tar.gz
tor-ceac10fc3d664a5d7ee910965a5e0d15ea67adb1.zip
rust: max_width=100, other rustfmt settings. #27071
These are the 12 stable and documented configuration options, set to their default values. use_small_heuristics is only stabilized in rustfmt 0.9, so maintain support for 0.8.x for now by commenting it out. comment_width is unstable and did nothing, since wrap_comments defaults to false. Default values gotten from `rustfmt --print-config default rustfmt.toml`. https://github.com/rust-lang-nursery/rustfmt/blob/e7932fa9c2591c45a37a24305de90cb63128afcf/Configurations.md
-rw-r--r--src/rust/.rustfmt.toml14
1 files changed, 12 insertions, 2 deletions
diff --git a/src/rust/.rustfmt.toml b/src/rust/.rustfmt.toml
index f25bd51883..4ff839dcf3 100644
--- a/src/rust/.rustfmt.toml
+++ b/src/rust/.rustfmt.toml
@@ -1,2 +1,12 @@
-max_width = 80
-comment_width = 80
+max_width = 100
+hard_tabs = false
+tab_spaces = 4
+newline_style = "Unix"
+#use_small_heuristics = "Default"
+reorder_imports = true
+reorder_modules = true
+remove_nested_parens = true
+merge_derives = true
+use_try_shorthand = false
+use_field_init_shorthand = false
+force_explicit_abi = true