]> git.lizzy.rs Git - rust.git/blob - src/test/ui/async-await/no-const-async.stderr
Rollup merge of #71627 - ldm0:autoderefarg, r=Dylan-DPC
[rust.git] / src / test / ui / async-await / no-const-async.stderr
1 error: functions cannot be both `const` and `async`
2   --> $DIR/no-const-async.rs:4:5
3    |
4 LL | pub const async fn x() {}
5    | ----^^^^^-^^^^^----------
6    |     |     |
7    |     |     `async` because of this
8    |     `const` because of this
9
10 error[E0723]: `impl Trait` in const fn is unstable
11   --> $DIR/no-const-async.rs:4:24
12    |
13 LL | pub const async fn x() {}
14    |                        ^
15    |
16    = note: see issue #57563 <https://github.com/rust-lang/rust/issues/57563> for more information
17    = help: add `#![feature(const_fn)]` to the crate attributes to enable
18
19 error: aborting due to 2 previous errors
20
21 For more information about this error, try `rustc --explain E0723`.