]> git.lizzy.rs Git - rust.git/blob - src/tools/rustfmt/tests/source/issue-4926/deeply_nested_struct_with_many_fields.rs
Rollup merge of #89876 - AlexApps99:const_ops, r=oli-obk
[rust.git] / src / tools / rustfmt / tests / source / issue-4926 / deeply_nested_struct_with_many_fields.rs
1 // rustfmt-struct_field_align_threshold: 30
2
3 struct X {
4     a: i32,
5     b: i32,
6     c: i32,
7     d: i32,
8     e: i32,
9     f: i32,
10     g: i32,
11     h: i32,
12     i: i32,
13     j: i32,
14     k: i32,
15 }
16
17 fn test(x: X) {
18     let d = {
19         let e = {
20             let f = {
21                 let g = {
22                     let h = {
23                         let i = {
24                             let j = {
25                                 matches!(
26                                     x,
27                                     X {
28                                         a: 1_000, b: 1_000, c: 1_000, d: 1_000, e: 1_000, f: 1_000, g: 1_000, h: 1_000, i: 1_000, j: 1_000, ..
29                                     }
30                                 )
31                             };
32                             j
33                         };
34                         i
35                     };
36                     h
37                 };
38                 g
39             };
40             f
41         };
42         e
43     };
44 }