fork/rust

git clone https://git.julia.blue/fork/rust

borsAuto merge of #71365 - Mark-Simulacrum:stable-next, r=Mark-Simulacrum4fb7144ed15

1.43.0
3.5 KiB105 linesraw
1error[E0670]: `async fn` is not permitted in the 2015 edition
2  --> $DIR/edition-deny-async-fns-2015.rs:3:1
3   |
4LL | async fn foo() {}
5   | ^^^^^
6   |
7   = note: to use `async fn`, switch to Rust 2018
8   = help: set `edition = "2018"` in `Cargo.toml`
9   = note: for more on editions, read https://doc.rust-lang.org/edition-guide
10
11error[E0670]: `async fn` is not permitted in the 2015 edition
12  --> $DIR/edition-deny-async-fns-2015.rs:5:12
13   |
14LL | fn baz() { async fn foo() {} }
15   |            ^^^^^
16   |
17   = note: to use `async fn`, switch to Rust 2018
18   = help: set `edition = "2018"` in `Cargo.toml`
19   = note: for more on editions, read https://doc.rust-lang.org/edition-guide
20
21error[E0670]: `async fn` is not permitted in the 2015 edition
22  --> $DIR/edition-deny-async-fns-2015.rs:7:1
23   |
24LL | async fn async_baz() {
25   | ^^^^^
26   |
27   = note: to use `async fn`, switch to Rust 2018
28   = help: set `edition = "2018"` in `Cargo.toml`
29   = note: for more on editions, read https://doc.rust-lang.org/edition-guide
30
31error[E0670]: `async fn` is not permitted in the 2015 edition
32  --> $DIR/edition-deny-async-fns-2015.rs:8:5
33   |
34LL |     async fn bar() {}
35   |     ^^^^^
36   |
37   = note: to use `async fn`, switch to Rust 2018
38   = help: set `edition = "2018"` in `Cargo.toml`
39   = note: for more on editions, read https://doc.rust-lang.org/edition-guide
40
41error[E0670]: `async fn` is not permitted in the 2015 edition
42  --> $DIR/edition-deny-async-fns-2015.rs:14:5
43   |
44LL |     async fn foo() {}
45   |     ^^^^^
46   |
47   = note: to use `async fn`, switch to Rust 2018
48   = help: set `edition = "2018"` in `Cargo.toml`
49   = note: for more on editions, read https://doc.rust-lang.org/edition-guide
50
51error[E0670]: `async fn` is not permitted in the 2015 edition
52  --> $DIR/edition-deny-async-fns-2015.rs:18:5
53   |
54LL |     async fn foo() {}
55   |     ^^^^^
56   |
57   = note: to use `async fn`, switch to Rust 2018
58   = help: set `edition = "2018"` in `Cargo.toml`
59   = note: for more on editions, read https://doc.rust-lang.org/edition-guide
60
61error[E0670]: `async fn` is not permitted in the 2015 edition
62  --> $DIR/edition-deny-async-fns-2015.rs:36:9
63   |
64LL |         async fn bar() {}
65   |         ^^^^^
66   |
67   = note: to use `async fn`, switch to Rust 2018
68   = help: set `edition = "2018"` in `Cargo.toml`
69   = note: for more on editions, read https://doc.rust-lang.org/edition-guide
70
71error[E0670]: `async fn` is not permitted in the 2015 edition
72  --> $DIR/edition-deny-async-fns-2015.rs:26:9
73   |
74LL |         async fn foo() {}
75   |         ^^^^^
76   |
77   = note: to use `async fn`, switch to Rust 2018
78   = help: set `edition = "2018"` in `Cargo.toml`
79   = note: for more on editions, read https://doc.rust-lang.org/edition-guide
80
81error[E0670]: `async fn` is not permitted in the 2015 edition
82  --> $DIR/edition-deny-async-fns-2015.rs:31:13
83   |
84LL |             async fn bar() {}
85   |             ^^^^^
86   |
87   = note: to use `async fn`, switch to Rust 2018
88   = help: set `edition = "2018"` in `Cargo.toml`
89   = note: for more on editions, read https://doc.rust-lang.org/edition-guide
90
91error[E0706]: functions in traits cannot be declared `async`
92  --> $DIR/edition-deny-async-fns-2015.rs:18:5
93   |
94LL |     async fn foo() {}
95   |     -----^^^^^^^^^^^^
96   |     |
97   |     `async` because of this
98   |
99   = note: `async` trait functions are not currently supported
100   = note: consider using the `async-trait` crate: https://crates.io/crates/async-trait
101
102error: aborting due to 10 previous errors
103
104Some errors have detailed explanations: E0670, E0706.
105For more information about an error, try `rustc --explain E0670`.