@@ -169,7 +169,7 @@ LL | const fn foo30_4(b: bool) -> usize { if b { 1 } else { 42 } }
169169 = note: for more information, see issue https://github.com/rust-lang/rust/issues/57563
170170 = help: add #![feature(const_fn)] to the crate attributes to enable
171171
172- error[E0723]: loops and conditional expressions are not stable in const fn
172+ error[E0723]: loops are not allowed in const fn
173173 --> $DIR/min_const_fn.rs:102:29
174174 |
175175LL | const fn foo30_5(b: bool) { while b { } }
@@ -179,7 +179,7 @@ LL | const fn foo30_5(b: bool) { while b { } }
179179 = help: add #![feature(const_fn)] to the crate attributes to enable
180180
181181error[E0723]: loops and conditional expressions are not stable in const fn
182- --> $DIR/min_const_fn.rs:104 :44
182+ --> $DIR/min_const_fn.rs:105 :44
183183 |
184184LL | const fn foo36(a: bool, b: bool) -> bool { a && b }
185185 | ^^^^^^
@@ -188,7 +188,7 @@ LL | const fn foo36(a: bool, b: bool) -> bool { a && b }
188188 = help: add #![feature(const_fn)] to the crate attributes to enable
189189
190190error[E0723]: loops and conditional expressions are not stable in const fn
191- --> $DIR/min_const_fn.rs:106 :44
191+ --> $DIR/min_const_fn.rs:107 :44
192192 |
193193LL | const fn foo37(a: bool, b: bool) -> bool { a || b }
194194 | ^^^^^^
@@ -197,7 +197,7 @@ LL | const fn foo37(a: bool, b: bool) -> bool { a || b }
197197 = help: add #![feature(const_fn)] to the crate attributes to enable
198198
199199error[E0723]: mutable references in const fn are unstable
200- --> $DIR/min_const_fn.rs:108 :14
200+ --> $DIR/min_const_fn.rs:109 :14
201201 |
202202LL | const fn inc(x: &mut i32) { *x += 1 }
203203 | ^
@@ -206,7 +206,7 @@ LL | const fn inc(x: &mut i32) { *x += 1 }
206206 = help: add #![feature(const_fn)] to the crate attributes to enable
207207
208208error[E0723]: trait bounds other than `Sized` on const fn parameters are unstable
209- --> $DIR/min_const_fn.rs:113 :6
209+ --> $DIR/min_const_fn.rs:114 :6
210210 |
211211LL | impl<T: std::fmt::Debug> Foo<T> {
212212 | ^
@@ -215,7 +215,7 @@ LL | impl<T: std::fmt::Debug> Foo<T> {
215215 = help: add #![feature(const_fn)] to the crate attributes to enable
216216
217217error[E0723]: trait bounds other than `Sized` on const fn parameters are unstable
218- --> $DIR/min_const_fn.rs:118 :6
218+ --> $DIR/min_const_fn.rs:119 :6
219219 |
220220LL | impl<T: std::fmt::Debug + Sized> Foo<T> {
221221 | ^
@@ -224,7 +224,7 @@ LL | impl<T: std::fmt::Debug + Sized> Foo<T> {
224224 = help: add #![feature(const_fn)] to the crate attributes to enable
225225
226226error[E0723]: trait bounds other than `Sized` on const fn parameters are unstable
227- --> $DIR/min_const_fn.rs:123 :6
227+ --> $DIR/min_const_fn.rs:124 :6
228228 |
229229LL | impl<T: Sync + Sized> Foo<T> {
230230 | ^
@@ -233,7 +233,7 @@ LL | impl<T: Sync + Sized> Foo<T> {
233233 = help: add #![feature(const_fn)] to the crate attributes to enable
234234
235235error[E0723]: `impl Trait` in const fn is unstable
236- --> $DIR/min_const_fn.rs:129 :24
236+ --> $DIR/min_const_fn.rs:130 :24
237237 |
238238LL | const fn no_rpit2() -> AlanTuring<impl std::fmt::Debug> { AlanTuring(0) }
239239 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -242,7 +242,7 @@ LL | const fn no_rpit2() -> AlanTuring<impl std::fmt::Debug> { AlanTuring(0) }
242242 = help: add #![feature(const_fn)] to the crate attributes to enable
243243
244244error[E0723]: trait bounds other than `Sized` on const fn parameters are unstable
245- --> $DIR/min_const_fn.rs:131 :34
245+ --> $DIR/min_const_fn.rs:132 :34
246246 |
247247LL | const fn no_apit2(_x: AlanTuring<impl std::fmt::Debug>) {}
248248 | ^^^^^^^^^^^^^^^^^^^^
@@ -251,7 +251,7 @@ LL | const fn no_apit2(_x: AlanTuring<impl std::fmt::Debug>) {}
251251 = help: add #![feature(const_fn)] to the crate attributes to enable
252252
253253error[E0723]: trait bounds other than `Sized` on const fn parameters are unstable
254- --> $DIR/min_const_fn.rs:133 :22
254+ --> $DIR/min_const_fn.rs:134 :22
255255 |
256256LL | const fn no_apit(_x: impl std::fmt::Debug) {}
257257 | ^^^^^^^^^^^^^^^^^^^^
@@ -260,7 +260,7 @@ LL | const fn no_apit(_x: impl std::fmt::Debug) {}
260260 = help: add #![feature(const_fn)] to the crate attributes to enable
261261
262262error[E0723]: `impl Trait` in const fn is unstable
263- --> $DIR/min_const_fn.rs:134 :23
263+ --> $DIR/min_const_fn.rs:135 :23
264264 |
265265LL | const fn no_rpit() -> impl std::fmt::Debug {}
266266 | ^^^^^^^^^^^^^^^^^^^^
@@ -269,7 +269,7 @@ LL | const fn no_rpit() -> impl std::fmt::Debug {}
269269 = help: add #![feature(const_fn)] to the crate attributes to enable
270270
271271error[E0723]: trait bounds other than `Sized` on const fn parameters are unstable
272- --> $DIR/min_const_fn.rs:135 :23
272+ --> $DIR/min_const_fn.rs:136 :23
273273 |
274274LL | const fn no_dyn_trait(_x: &dyn std::fmt::Debug) {}
275275 | ^^
@@ -278,7 +278,7 @@ LL | const fn no_dyn_trait(_x: &dyn std::fmt::Debug) {}
278278 = help: add #![feature(const_fn)] to the crate attributes to enable
279279
280280error[E0723]: trait bounds other than `Sized` on const fn parameters are unstable
281- --> $DIR/min_const_fn.rs:136 :32
281+ --> $DIR/min_const_fn.rs:137 :32
282282 |
283283LL | const fn no_dyn_trait_ret() -> &'static dyn std::fmt::Debug { &() }
284284 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -287,7 +287,7 @@ LL | const fn no_dyn_trait_ret() -> &'static dyn std::fmt::Debug { &() }
287287 = help: add #![feature(const_fn)] to the crate attributes to enable
288288
289289error[E0515]: cannot return reference to temporary value
290- --> $DIR/min_const_fn.rs:136 :63
290+ --> $DIR/min_const_fn.rs:137 :63
291291 |
292292LL | const fn no_dyn_trait_ret() -> &'static dyn std::fmt::Debug { &() }
293293 | ^--
@@ -296,7 +296,7 @@ LL | const fn no_dyn_trait_ret() -> &'static dyn std::fmt::Debug { &() }
296296 | returns a reference to data owned by the current function
297297
298298error[E0723]: trait bounds other than `Sized` on const fn parameters are unstable
299- --> $DIR/min_const_fn.rs:144 :41
299+ --> $DIR/min_const_fn.rs:145 :41
300300 |
301301LL | const fn really_no_traits_i_mean_it() { (&() as &dyn std::fmt::Debug, ()).1 }
302302 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -305,7 +305,7 @@ LL | const fn really_no_traits_i_mean_it() { (&() as &dyn std::fmt::Debug, ()).1
305305 = help: add #![feature(const_fn)] to the crate attributes to enable
306306
307307error[E0723]: function pointers in const fn are unstable
308- --> $DIR/min_const_fn.rs:147 :21
308+ --> $DIR/min_const_fn.rs:148 :21
309309 |
310310LL | const fn no_fn_ptrs(_x: fn()) {}
311311 | ^^
@@ -314,7 +314,7 @@ LL | const fn no_fn_ptrs(_x: fn()) {}
314314 = help: add #![feature(const_fn)] to the crate attributes to enable
315315
316316error[E0723]: function pointers in const fn are unstable
317- --> $DIR/min_const_fn.rs:149 :27
317+ --> $DIR/min_const_fn.rs:150 :27
318318 |
319319LL | const fn no_fn_ptrs2() -> fn() { fn foo() {} foo }
320320 | ^^^^
0 commit comments