-
Notifications
You must be signed in to change notification settings - Fork 933
fn_width config option #6046
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
fn_width config option #6046
Changes from 2 commits
4926b7e
86f6073
1bcd1e3
c48181e
7e4ab07
118e6ec
9d1d649
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
max_width = 100 | ||
fn_width = 100 |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
max_width = 150 | ||
fn_width = 150 |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
max_width = 50 | ||
fn_width = 50 |
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. let's move these tests to There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I assume you meant the |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
// rustfmt-config: fn_width_100.toml | ||
Sjael marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
impl Trait { | ||
fn lorem(first: First, second: Second); | ||
fn lorem(first: FirstParameter, second: SecondParameter, third: ThirdParameter); | ||
fn lorem(first: FirstParameter, second: SecondParameter, third: ThirdParameter, fourth: FourthParameter); | ||
Sjael marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
fn lorem(first: First, second: Second) { | ||
// block | ||
} | ||
fn lorem(first: FirstParameter, second: SecondParameter, third: ThirdParameter) { | ||
// block | ||
} | ||
fn lorem(first: FirstParameter, second: SecondParameter, third: ThirdParameter, fourth: FourthParameter) { | ||
// block | ||
} | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
// rustfmt-config: fn_width_150.toml | ||
|
||
impl Trait { | ||
fn lorem(first: First, second: Second); | ||
fn lorem(first: FirstParameter, second: SecondParameter, third: ThirdParameter); | ||
fn lorem(first: FirstParameter, second: SecondParameter, third: ThirdParameter, fourth: FourthParameter); | ||
|
||
fn lorem(first: First, second: Second) { | ||
// block | ||
} | ||
fn lorem(first: FirstParameter, second: SecondParameter, third: ThirdParameter) { | ||
// block | ||
} | ||
fn lorem(first: FirstParameter, second: SecondParameter, third: ThirdParameter, fourth: FourthParameter) { | ||
// block | ||
} | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
// rustfmt-config: fn_width_50.toml | ||
|
||
impl Trait { | ||
fn lorem(first: First, second: Second); | ||
fn lorem(first: FirstParameter, second: SecondParameter, third: ThirdParameter); | ||
fn lorem(first: FirstParameter, second: SecondParameter, third: ThirdParameter, fourth: FourthParameter); | ||
|
||
fn lorem(first: First, second: Second) { | ||
// block | ||
} | ||
fn lorem(first: FirstParameter, second: SecondParameter, third: ThirdParameter) { | ||
// block | ||
} | ||
fn lorem(first: FirstParameter, second: SecondParameter, third: ThirdParameter, fourth: FourthParameter) { | ||
// block | ||
} | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
// rustfmt-config: fn_width_100.toml | ||
|
||
impl Trait { | ||
fn lorem(first: First, second: Second); | ||
fn lorem(first: FirstParameter, second: SecondParameter, third: ThirdParameter); | ||
fn lorem( | ||
first: FirstParameter, | ||
second: SecondParameter, | ||
third: ThirdParameter, | ||
fourth: FourthParameter, | ||
); | ||
|
||
fn lorem(first: First, second: Second) { | ||
// block | ||
} | ||
fn lorem(first: FirstParameter, second: SecondParameter, third: ThirdParameter) { | ||
// block | ||
} | ||
fn lorem( | ||
first: FirstParameter, | ||
second: SecondParameter, | ||
third: ThirdParameter, | ||
fourth: FourthParameter, | ||
) { | ||
// block | ||
} | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
// rustfmt-config: fn_width_150.toml | ||
|
||
impl Trait { | ||
fn lorem(first: First, second: Second); | ||
fn lorem(first: FirstParameter, second: SecondParameter, third: ThirdParameter); | ||
fn lorem(first: FirstParameter, second: SecondParameter, third: ThirdParameter, fourth: FourthParameter); | ||
|
||
fn lorem(first: First, second: Second) { | ||
// block | ||
} | ||
fn lorem(first: FirstParameter, second: SecondParameter, third: ThirdParameter) { | ||
// block | ||
} | ||
fn lorem(first: FirstParameter, second: SecondParameter, third: ThirdParameter, fourth: FourthParameter) { | ||
// block | ||
} | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
// rustfmt-config: fn_width_50.toml | ||
|
||
impl Trait { | ||
fn lorem(first: First, second: Second); | ||
fn lorem( | ||
first: FirstParameter, | ||
second: SecondParameter, | ||
third: ThirdParameter, | ||
); | ||
fn lorem( | ||
first: FirstParameter, | ||
second: SecondParameter, | ||
third: ThirdParameter, | ||
fourth: FourthParameter, | ||
); | ||
|
||
fn lorem(first: First, second: Second) { | ||
// block | ||
} | ||
fn lorem( | ||
first: FirstParameter, | ||
second: SecondParameter, | ||
third: ThirdParameter, | ||
) { | ||
// block | ||
} | ||
fn lorem( | ||
first: FirstParameter, | ||
second: SecondParameter, | ||
third: ThirdParameter, | ||
fourth: FourthParameter, | ||
) { | ||
// block | ||
} | ||
} |
Uh oh!
There was an error while loading. Please reload this page.