You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: tests/ui/drop/lint-if-let-rescope.stderr
+43-3Lines changed: 43 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -132,7 +132,7 @@ LL | if let () = { match Droppy.get() { Some(_value) => {} _ => {}} } {
132
132
| ~~~~~ +++++++++++++++++ ++++++++
133
133
134
134
error: `if let` assigns a shorter lifetime since Edition 2024
135
-
--> $DIR/lint-if-let-rescope.rs:72:12
135
+
--> $DIR/lint-if-let-rescope.rs:73:12
136
136
|
137
137
LL | if (if let Some(_value) = droppy().get() { true } else { false }) {
138
138
| ^^^^^^^^^^^^^^^^^^^--------^^^^^^
@@ -142,7 +142,7 @@ LL | if (if let Some(_value) = droppy().get() { true } else { false }) {
142
142
= warning: this changes meaning in Rust 2024
143
143
= note: for more information, see issue #124085 <https://github.com/rust-lang/rust/issues/124085>
144
144
help: the value is now dropped here in Edition 2024
145
-
--> $DIR/lint-if-let-rescope.rs:72:53
145
+
--> $DIR/lint-if-let-rescope.rs:73:53
146
146
|
147
147
LL | if (if let Some(_value) = droppy().get() { true } else { false }) {
148
148
| ^
@@ -151,5 +151,45 @@ help: a `match` with a single arm can preserve the drop order up to Edition 2021
error: `if let` assigns a shorter lifetime since Edition 2024
155
+
--> $DIR/lint-if-let-rescope.rs:79:21
156
+
|
157
+
LL | } else if (((if let Some(_value) = droppy().get() { true } else { false }))) {
158
+
| ^^^^^^^^^^^^^^^^^^^--------^^^^^^
159
+
| |
160
+
| this value has a significant drop implementation which may observe a major change in drop order and requires your discretion
161
+
|
162
+
= warning: this changes meaning in Rust 2024
163
+
= note: for more information, see issue #124085 <https://github.com/rust-lang/rust/issues/124085>
164
+
help: the value is now dropped here in Edition 2024
165
+
--> $DIR/lint-if-let-rescope.rs:79:62
166
+
|
167
+
LL | } else if (((if let Some(_value) = droppy().get() { true } else { false }))) {
168
+
| ^
169
+
help: a `match` with a single arm can preserve the drop order up to Edition 2021
error: `if let` assigns a shorter lifetime since Edition 2024
175
+
--> $DIR/lint-if-let-rescope.rs:91:15
176
+
|
177
+
LL | while (if let Some(_value) = droppy().get() { false } else { true }) {
178
+
| ^^^^^^^^^^^^^^^^^^^--------^^^^^^
179
+
| |
180
+
| this value has a significant drop implementation which may observe a major change in drop order and requires your discretion
181
+
|
182
+
= warning: this changes meaning in Rust 2024
183
+
= note: for more information, see issue #124085 <https://github.com/rust-lang/rust/issues/124085>
184
+
help: the value is now dropped here in Edition 2024
185
+
--> $DIR/lint-if-let-rescope.rs:91:57
186
+
|
187
+
LL | while (if let Some(_value) = droppy().get() { false } else { true }) {
188
+
| ^
189
+
help: a `match` with a single arm can preserve the drop order up to Edition 2021
0 commit comments