@@ -47,17 +47,32 @@ error: future cannot be sent between threads safely
47
47
--> $DIR/future_not_send.rs:20:63
48
48
|
49
49
LL | async fn private_future2(rc: Rc<[u8]>, cell: &Cell<usize>) -> bool {
50
- | ^^^^
50
+ | ^^^^ future returned by `private_future2` is not `Send`
51
51
|
52
+ note: captured value is not `Send`
53
+ --> $DIR/future_not_send.rs:20:26
54
+ |
55
+ LL | async fn private_future2(rc: Rc<[u8]>, cell: &Cell<usize>) -> bool {
56
+ | ^^ has type `std::rc::Rc<[u8]>` which is not `Send`
52
57
= note: `std::rc::Rc<[u8]>` doesn't implement `std::marker::Send`
58
+ note: captured value is not `Send`
59
+ --> $DIR/future_not_send.rs:20:40
60
+ |
61
+ LL | async fn private_future2(rc: Rc<[u8]>, cell: &Cell<usize>) -> bool {
62
+ | ^^^^ has type `&std::cell::Cell<usize>` which is not `Send`
53
63
= note: `std::cell::Cell<usize>` doesn't implement `std::marker::Sync`
54
64
55
65
error: future cannot be sent between threads safely
56
66
--> $DIR/future_not_send.rs:24:43
57
67
|
58
68
LL | pub async fn public_future2(rc: Rc<[u8]>) {}
59
- | ^
69
+ | ^ future returned by `public_future2` is not `Send`
60
70
|
71
+ note: captured value is not `Send`
72
+ --> $DIR/future_not_send.rs:24:29
73
+ |
74
+ LL | pub async fn public_future2(rc: Rc<[u8]>) {}
75
+ | ^^ has type `std::rc::Rc<[u8]>` which is not `Send`
61
76
= note: `std::rc::Rc<[u8]>` doesn't implement `std::marker::Send`
62
77
63
78
error: future cannot be sent between threads safely
@@ -117,8 +132,13 @@ error: future cannot be sent between threads safely
117
132
--> $DIR/future_not_send.rs:66:34
118
133
|
119
134
LL | async fn unclear_future<T>(t: T) {}
120
- | ^
135
+ | ^ future returned by `unclear_future` is not `Send`
121
136
|
137
+ note: captured value is not `Send`
138
+ --> $DIR/future_not_send.rs:66:28
139
+ |
140
+ LL | async fn unclear_future<T>(t: T) {}
141
+ | ^ has type `T` which is not `Send`
122
142
= note: `T` doesn't implement `std::marker::Send`
123
143
124
144
error: aborting due to 8 previous errors
0 commit comments