File tree 2 files changed +33
-1
lines changed
2 files changed +33
-1
lines changed Original file line number Diff line number Diff line change @@ -10,12 +10,20 @@ async fn foo() {
10
10
//~^ ERROR type inside `async fn` body must be known in this context
11
11
//~| ERROR type inside `async fn` body must be known in this context
12
12
//~| ERROR type inside `async fn` body must be known in this context
13
+ //~| ERROR type inside `async fn` body must be known in this context
14
+ //~| ERROR type inside `async fn` body must be known in this context
15
+ //~| NOTE cannot infer type for type parameter `T`
16
+ //~| NOTE cannot infer type for type parameter `T`
13
17
//~| NOTE cannot infer type for type parameter `T`
14
18
//~| NOTE cannot infer type for type parameter `T`
15
19
//~| NOTE cannot infer type for type parameter `T`
16
20
//~| NOTE the type is part of the `async fn` body because of this `await`
17
21
//~| NOTE the type is part of the `async fn` body because of this `await`
18
22
//~| NOTE the type is part of the `async fn` body because of this `await`
23
+ //~| NOTE the type is part of the `async fn` body because of this `await`
24
+ //~| NOTE the type is part of the `async fn` body because of this `await`
25
+ //~| NOTE in this expansion of desugaring of `await`
26
+ //~| NOTE in this expansion of desugaring of `await`
19
27
//~| NOTE in this expansion of desugaring of `await`
20
28
//~| NOTE in this expansion of desugaring of `await`
21
29
//~| NOTE in this expansion of desugaring of `await`
Original file line number Diff line number Diff line change @@ -34,6 +34,30 @@ note: the type is part of the `async fn` body because of this `await`
34
34
LL | bar().await;
35
35
| ^^^^^^^^^^^
36
36
37
- error: aborting due to 3 previous errors
37
+ error[E0698]: type inside `async fn` body must be known in this context
38
+ --> $DIR/unresolved_type_param.rs:9:5
39
+ |
40
+ LL | bar().await;
41
+ | ^^^ cannot infer type for type parameter `T` declared on the function `bar`
42
+ |
43
+ note: the type is part of the `async fn` body because of this `await`
44
+ --> $DIR/unresolved_type_param.rs:9:5
45
+ |
46
+ LL | bar().await;
47
+ | ^^^^^^^^^^^
48
+
49
+ error[E0698]: type inside `async fn` body must be known in this context
50
+ --> $DIR/unresolved_type_param.rs:9:5
51
+ |
52
+ LL | bar().await;
53
+ | ^^^ cannot infer type for type parameter `T` declared on the function `bar`
54
+ |
55
+ note: the type is part of the `async fn` body because of this `await`
56
+ --> $DIR/unresolved_type_param.rs:9:5
57
+ |
58
+ LL | bar().await;
59
+ | ^^^^^^^^^^^
60
+
61
+ error: aborting due to 5 previous errors
38
62
39
63
For more information about this error, try `rustc --explain E0698`.
You can’t perform that action at this time.
0 commit comments