1error: this `if` has identical blocks
2  --> $DIR/if_same_then_else.rs:21:13
3   |
4LL |       if true {
5   |  _____________^
6LL | |         Foo { bar: 42 };
7LL | |         0..10;
8LL | |         ..;
9...  |
10LL | |         foo();
11LL | |     } else {
12   | |_____^
13   |
14   = note: `-D clippy::if-same-then-else` implied by `-D warnings`
15note: same as this
16  --> $DIR/if_same_then_else.rs:29:12
17   |
18LL |       } else {
19   |  ____________^
20LL | |         //~ ERROR same body as `if` block
21LL | |         Foo { bar: 42 };
22LL | |         0..10;
23...  |
24LL | |         foo();
25LL | |     }
26   | |_____^
27
28error: this `if` has identical blocks
29  --> $DIR/if_same_then_else.rs:65:21
30   |
31LL |       let _ = if true {
32   |  _____________________^
33LL | |         0.0
34LL | |     } else {
35   | |_____^
36   |
37note: same as this
38  --> $DIR/if_same_then_else.rs:67:12
39   |
40LL |       } else {
41   |  ____________^
42LL | |         //~ ERROR same body as `if` block
43LL | |         0.0
44LL | |     };
45   | |_____^
46
47error: this `if` has identical blocks
48  --> $DIR/if_same_then_else.rs:72:21
49   |
50LL |       let _ = if true {
51   |  _____________________^
52LL | |         -0.0
53LL | |     } else {
54   | |_____^
55   |
56note: same as this
57  --> $DIR/if_same_then_else.rs:74:12
58   |
59LL |       } else {
60   |  ____________^
61LL | |         //~ ERROR same body as `if` block
62LL | |         -0.0
63LL | |     };
64   | |_____^
65
66error: this `if` has identical blocks
67  --> $DIR/if_same_then_else.rs:88:21
68   |
69LL |       let _ = if true {
70   |  _____________________^
71LL | |         42
72LL | |     } else {
73   | |_____^
74   |
75note: same as this
76  --> $DIR/if_same_then_else.rs:90:12
77   |
78LL |       } else {
79   |  ____________^
80LL | |         //~ ERROR same body as `if` block
81LL | |         42
82LL | |     };
83   | |_____^
84
85error: this `if` has identical blocks
86  --> $DIR/if_same_then_else.rs:95:13
87   |
88LL |       if true {
89   |  _____________^
90LL | |         let bar = if true { 42 } else { 43 };
91LL | |
92LL | |         while foo() {
93...  |
94LL | |         bar + 1;
95LL | |     } else {
96   | |_____^
97   |
98note: same as this
99  --> $DIR/if_same_then_else.rs:102:12
100   |
101LL |       } else {
102   |  ____________^
103LL | |         //~ ERROR same body as `if` block
104LL | |         let bar = if true { 42 } else { 43 };
105LL | |
106...  |
107LL | |         bar + 1;
108LL | |     }
109   | |_____^
110
111error: aborting due to 5 previous errors
112
113