File tree Expand file tree Collapse file tree 1 file changed +49
-0
lines changed Expand file tree Collapse file tree 1 file changed +49
-0
lines changed Original file line number Diff line number Diff line change @@ -2001,6 +2001,55 @@ fn main() {
20012001}
20022002```
20032003
2004+ ## ` strip_leading_match_arm_pipes `
2005+
2006+ Controls whether to remove leading pipes from match arms
2007+
2008+ - ** Default value** : ` true `
2009+ - ** Possible values** : ` true ` , ` false `
2010+ - ** Stable** : Yes
2011+
2012+ #### ` true ` :
2013+ ``` rust
2014+ // Leading pipes are from this:
2015+ // fn foo() {
2016+ // match foo {
2017+ // | "foo" | "bar" => {}
2018+ // | "baz"
2019+ // | "something relatively long"
2020+ // | "something really really really realllllllllllllly long" => println!("x"),
2021+ // | "qux" => println!("y"),
2022+ // _ => {}
2023+ // }
2024+ // }
2025+
2026+ // Are removed:
2027+ fn foo () {
2028+ match foo {
2029+ " foo" | " bar" => {}
2030+ " baz"
2031+ | " something relatively long"
2032+ | " something really really really realllllllllllllly long" => println! (" x" ),
2033+ " qux" => println! (" y" ),
2034+ _ => {}
2035+ }
2036+ }
2037+ ```
2038+
2039+ #### ` false ` :
2040+ ``` rust
2041+ fn foo () {
2042+ match foo {
2043+ | " foo" | " bar" => {}
2044+ | " baz"
2045+ | " something relatively long"
2046+ | " something really really really realllllllllllllly long" => println! (" x" ),
2047+ | " qux" => println! (" y" ),
2048+ _ => {}
2049+ }
2050+ }
2051+ ```
2052+
20042053## ` struct_field_align_threshold `
20052054
20062055The maximum diff of width between struct fields to be aligned with each other.
You can’t perform that action at this time.
0 commit comments