]> git.lizzy.rs Git - rust.git/blob - src/test/ui/resolve/issue-70736-async-fn-no-body-def-collector.stderr
Rollup merge of #87180 - notriddle:notriddle/sidebar-keyboard-mobile, r=GuillaumeGomez
[rust.git] / src / test / ui / resolve / issue-70736-async-fn-no-body-def-collector.stderr
1 error: free function without a body
2   --> $DIR/issue-70736-async-fn-no-body-def-collector.rs:3:1
3    |
4 LL | async fn free();
5    | ^^^^^^^^^^^^^^^-
6    |                |
7    |                help: provide a definition for the function: `{ <body> }`
8
9 error: associated function in `impl` without body
10   --> $DIR/issue-70736-async-fn-no-body-def-collector.rs:7:5
11    |
12 LL |     async fn inherent();
13    |     ^^^^^^^^^^^^^^^^^^^-
14    |                        |
15    |                        help: provide a definition for the function: `{ <body> }`
16
17 error[E0706]: functions in traits cannot be declared `async`
18   --> $DIR/issue-70736-async-fn-no-body-def-collector.rs:11:5
19    |
20 LL |     async fn associated();
21    |     -----^^^^^^^^^^^^^^^^^
22    |     |
23    |     `async` because of this
24    |
25    = note: `async` trait functions are not currently supported
26    = note: consider using the `async-trait` crate: https://crates.io/crates/async-trait
27
28 error: associated function in `impl` without body
29   --> $DIR/issue-70736-async-fn-no-body-def-collector.rs:15:5
30    |
31 LL |     async fn associated();
32    |     ^^^^^^^^^^^^^^^^^^^^^-
33    |                          |
34    |                          help: provide a definition for the function: `{ <body> }`
35
36 error[E0706]: functions in traits cannot be declared `async`
37   --> $DIR/issue-70736-async-fn-no-body-def-collector.rs:15:5
38    |
39 LL |     async fn associated();
40    |     -----^^^^^^^^^^^^^^^^^
41    |     |
42    |     `async` because of this
43    |
44    = note: `async` trait functions are not currently supported
45    = note: consider using the `async-trait` crate: https://crates.io/crates/async-trait
46
47 error[E0053]: method `associated` has an incompatible type for trait
48   --> $DIR/issue-70736-async-fn-no-body-def-collector.rs:15:26
49    |
50 LL |     async fn associated();
51    |                          - type in trait
52 ...
53 LL |     async fn associated();
54    |                          ^
55    |                          |
56    |                          checked the `Output` of this `async fn`, found opaque type
57    |                          expected `()`, found opaque type
58    |
59    = note: while checking the return type of the `async fn`
60    = note: expected fn pointer `fn()`
61               found fn pointer `fn() -> impl Future`
62
63 error: aborting due to 6 previous errors
64
65 Some errors have detailed explanations: E0053, E0706.
66 For more information about an error, try `rustc --explain E0053`.