]> git.proxmox.com Git - rustc.git/blame - src/tools/rustfmt/tests/target/else-if-brace-style-always-same-line.rs
Update upstream source from tag 'upstream/1.52.1+dfsg1'
[rustc.git] / src / tools / rustfmt / tests / target / else-if-brace-style-always-same-line.rs
CommitLineData
f20569fa
XL
1fn main() {
2 if false {
3 ();
4 ();
5 }
6
7 if false
8 // lone if comment
9 {
10 ();
11 ();
12 }
13
14 let a = if 0 > 1 { unreachable!() } else { 0x0 };
15
16 if true {
17 ();
18 } else if false {
19 ();
20 ();
21 } else {
22 ();
23 ();
24 ();
25 }
26
27 if true
28 // else-if-chain if comment
29 {
30 ();
31 } else if false
32 // else-if-chain else-if comment
33 {
34 ();
35 ();
36 } else
37 // else-if-chain else comment
38 {
39 ();
40 ();
41 ();
42 }
43}