rust/tests/target/fn-custom-2.rs
Nick Cameron 86007e7d17 Remove where_density and where_layout options
There is a choice between block and visual indent for where clauses, plus the
single line option. I think these two are too fine-grained to be useful.
2017-11-24 21:08:24 +13:00

79 lines
1.2 KiB
Rust

// rustfmt-indent_style: Block
// Test different indents.
fn foo(
a: Aaaaaaaaaaaaaaa,
b: Bbbbbbbbbbbbbbbb,
c: Ccccccccccccccccc,
d: Ddddddddddddddddddddddddd,
e: Eeeeeeeeeeeeeeeeeee,
) {
foo();
}
fn bar<
'a: 'bbbbbbbbbbbbbbbbbbbbbbbbbbb,
TTTTTTTTTTTTT,
UUUUUUUUUUUUUUUUUUUU: WWWWWWWWWWWWWWWWWWWWWWWW,
>(
a: Aaaaaaaaaaaaaaa,
) {
bar();
}
fn baz()
where
X: TTTTTTTT,
{
baz();
}
fn qux()
where
X: TTTTTTTTTTTTTTTTTTTTTTTTTTTT,
X: TTTTTTTTTTTTTTTTTTTTTTTTTTTT,
X: TTTTTTTTTTTTTTTTTTTTTTTTTTTT,
X: TTTTTTTTTTTTTTTTTTTTTTTTTTTT,
{
baz();
}
impl Foo {
fn foo(
self,
a: Aaaaaaaaaaaaaaa,
b: Bbbbbbbbbbbbbbbb,
c: Ccccccccccccccccc,
d: Ddddddddddddddddddddddddd,
e: Eeeeeeeeeeeeeeeeeee,
) {
foo();
}
fn bar<
'a: 'bbbbbbbbbbbbbbbbbbbbbbbbbbb,
TTTTTTTTTTTTT,
UUUUUUUUUUUUUUUUUUUU: WWWWWWWWWWWWWWWWWWWWWWWW,
>(
a: Aaaaaaaaaaaaaaa,
) {
bar();
}
fn baz()
where
X: TTTTTTTT,
{
baz();
}
}
struct Foo<
TTTTTTTTTTTTTTTTTTTTTTTTTTTT,
UUUUUUUUUUUUUUUUUUUUUU,
VVVVVVVVVVVVVVVVVVVVVVVVVVV,
WWWWWWWWWWWWWWWWWWWWWWWW,
> {
foo: Foo,
}