@@ -6,22 +6,22 @@ LL | async fn private_future(rc: Rc<[u8]>, cell: &Cell<usize>) -> bool {
6
6
|
7
7
= note: `-D clippy::future-not-send` implied by `-D warnings`
8
8
note: future is not `Send` as this value is used across an await
9
- --> $DIR/future_not_send.rs:8:5
9
+ --> $DIR/future_not_send.rs:8:19
10
10
|
11
11
LL | async fn private_future(rc: Rc<[u8]>, cell: &Cell<usize>) -> bool {
12
12
| -- has type `std::rc::Rc<[u8]>` which is not `Send`
13
13
LL | async { true }.await
14
- | ^^^^^^^^^^^^^^ ^^^^^^ await occurs here, with `rc` maybe used later
14
+ | ^^^^^^ await occurs here, with `rc` maybe used later
15
15
LL | }
16
16
| - `rc` is later dropped here
17
17
= note: `std::rc::Rc<[u8]>` doesn't implement `std::marker::Send`
18
18
note: future is not `Send` as this value is used across an await
19
- --> $DIR/future_not_send.rs:8:5
19
+ --> $DIR/future_not_send.rs:8:19
20
20
|
21
21
LL | async fn private_future(rc: Rc<[u8]>, cell: &Cell<usize>) -> bool {
22
22
| ---- has type `&std::cell::Cell<usize>` which is not `Send`
23
23
LL | async { true }.await
24
- | ^^^^^^^^^^^^^^ ^^^^^^ await occurs here, with `cell` maybe used later
24
+ | ^^^^^^ await occurs here, with `cell` maybe used later
25
25
LL | }
26
26
| - `cell` is later dropped here
27
27
= note: `std::cell::Cell<usize>` doesn't implement `std::marker::Sync`
@@ -33,12 +33,12 @@ LL | pub async fn public_future(rc: Rc<[u8]>) {
33
33
| ^ future returned by `public_future` is not `Send`
34
34
|
35
35
note: future is not `Send` as this value is used across an await
36
- --> $DIR/future_not_send.rs:12:5
36
+ --> $DIR/future_not_send.rs:12:19
37
37
|
38
38
LL | pub async fn public_future(rc: Rc<[u8]>) {
39
39
| -- has type `std::rc::Rc<[u8]>` which is not `Send`
40
40
LL | async { true }.await;
41
- | ^^^^^^^^^^^^^^ ^^^^^^ await occurs here, with `rc` maybe used later
41
+ | ^^^^^^ await occurs here, with `rc` maybe used later
42
42
LL | }
43
43
| - `rc` is later dropped here
44
44
= note: `std::rc::Rc<[u8]>` doesn't implement `std::marker::Send`
@@ -82,12 +82,12 @@ LL | async fn private_future(&self) -> usize {
82
82
| ^^^^^ future returned by `private_future` is not `Send`
83
83
|
84
84
note: future is not `Send` as this value is used across an await
85
- --> $DIR/future_not_send.rs:35:9
85
+ --> $DIR/future_not_send.rs:35:23
86
86
|
87
87
LL | async fn private_future(&self) -> usize {
88
88
| ----- has type `&Dummy` which is not `Send`
89
89
LL | async { true }.await;
90
- | ^^^^^^^^^^^^^^ ^^^^^^ await occurs here, with `&self` maybe used later
90
+ | ^^^^^^ await occurs here, with `&self` maybe used later
91
91
LL | self.rc.len()
92
92
LL | }
93
93
| - `&self` is later dropped here
@@ -100,12 +100,12 @@ LL | pub async fn public_future(&self) {
100
100
| ^ future returned by `public_future` is not `Send`
101
101
|
102
102
note: future is not `Send` as this value is used across an await
103
- --> $DIR/future_not_send.rs:40:9
103
+ --> $DIR/future_not_send.rs:40:30
104
104
|
105
105
LL | pub async fn public_future(&self) {
106
106
| ----- has type `&Dummy` which is not `Send`
107
107
LL | self.private_future().await;
108
- | ^^^^^^^^^^^^^^^^^^^^^ ^^^^^^ await occurs here, with `&self` maybe used later
108
+ | ^^^^^^ await occurs here, with `&self` maybe used later
109
109
LL | }
110
110
| - `&self` is later dropped here
111
111
= note: `std::rc::Rc<[u8]>` doesn't implement `std::marker::Sync`
@@ -117,12 +117,12 @@ LL | async fn generic_future<T>(t: T) -> T
117
117
| ^ future returned by `generic_future` is not `Send`
118
118
|
119
119
note: future is not `Send` as this value is used across an await
120
- --> $DIR/future_not_send.rs:54:5
120
+ --> $DIR/future_not_send.rs:54:19
121
121
|
122
122
LL | let rt = &t;
123
123
| -- has type `&T` which is not `Send`
124
124
LL | async { true }.await;
125
- | ^^^^^^^^^^^^^^ ^^^^^^ await occurs here, with `rt` maybe used later
125
+ | ^^^^^^ await occurs here, with `rt` maybe used later
126
126
LL | t
127
127
LL | }
128
128
| - `rt` is later dropped here
0 commit comments