|
1 |
| -warning: unused variable: `url` |
2 |
| - --> tests/ui/consider-restricting.rs:16:41 |
3 |
| - | |
4 |
| -16 | async fn publish<T: IntoUrl>(&self, url: T) {} |
5 |
| - | ^^^ help: if this is intentional, prefix it with an underscore: `_url` |
6 |
| - | |
7 |
| - = note: `#[warn(unused_variables)]` on by default |
8 |
| - |
9 | 1 | error: future cannot be sent between threads safely
|
10 |
| - --> tests/ui/consider-restricting.rs:16:49 |
| 2 | + --> tests/ui/consider-restricting.rs:16:50 |
11 | 3 | |
|
12 |
| -16 | async fn publish<T: IntoUrl>(&self, url: T) {} |
13 |
| - | ^^ future created by async block is not `Send` |
| 4 | +16 | async fn publish<T: IntoUrl>(&self, _url: T) {} |
| 5 | + | ^^ future created by async block is not `Send` |
14 | 6 | |
|
15 | 7 | note: captured value is not `Send`
|
16 | 8 | --> tests/ui/consider-restricting.rs:16:41
|
17 | 9 | |
|
18 |
| -16 | async fn publish<T: IntoUrl>(&self, url: T) {} |
19 |
| - | ^^^ has type `T` which is not `Send` |
20 |
| - = note: required for the cast from `Pin<Box<{async block@$DIR/tests/ui/consider-restricting.rs:16:49: 16:51}>>` to `Pin<Box<dyn Future<Output = ()> + Send>>` |
| 10 | +16 | async fn publish<T: IntoUrl>(&self, _url: T) {} |
| 11 | + | ^^^^ has type `T` which is not `Send` |
| 12 | + = note: required for the cast from `Pin<Box<{async block@$DIR/tests/ui/consider-restricting.rs:16:50: 16:52}>>` to `Pin<Box<dyn Future<Output = ()> + Send>>` |
21 | 13 | help: consider further restricting type parameter `T` with trait `Send`
|
22 | 14 | |
|
23 |
| -16 | async fn publish<T: IntoUrl + std::marker::Send>(&self, url: T) {} |
| 15 | +16 | async fn publish<T: IntoUrl + std::marker::Send>(&self, _url: T) {} |
24 | 16 | | +++++++++++++++++++
|
25 | 17 |
|
26 |
| -warning: unused variable: `url` |
27 |
| - --> tests/ui/consider-restricting.rs:23:32 |
28 |
| - | |
29 |
| -23 | async fn publish<T>(&self, url: T) {} |
30 |
| - | ^^^ help: if this is intentional, prefix it with an underscore: `_url` |
31 |
| - |
32 | 18 | error: future cannot be sent between threads safely
|
33 |
| - --> tests/ui/consider-restricting.rs:23:40 |
| 19 | + --> tests/ui/consider-restricting.rs:23:41 |
34 | 20 | |
|
35 |
| -23 | async fn publish<T>(&self, url: T) {} |
36 |
| - | ^^ future created by async block is not `Send` |
| 21 | +23 | async fn publish<T>(&self, _url: T) {} |
| 22 | + | ^^ future created by async block is not `Send` |
37 | 23 | |
|
38 | 24 | note: captured value is not `Send`
|
39 | 25 | --> tests/ui/consider-restricting.rs:23:32
|
40 | 26 | |
|
41 |
| -23 | async fn publish<T>(&self, url: T) {} |
42 |
| - | ^^^ has type `T` which is not `Send` |
43 |
| - = note: required for the cast from `Pin<Box<{async block@$DIR/tests/ui/consider-restricting.rs:23:40: 23:42}>>` to `Pin<Box<dyn Future<Output = ()> + Send>>` |
| 27 | +23 | async fn publish<T>(&self, _url: T) {} |
| 28 | + | ^^^^ has type `T` which is not `Send` |
| 29 | + = note: required for the cast from `Pin<Box<{async block@$DIR/tests/ui/consider-restricting.rs:23:41: 23:43}>>` to `Pin<Box<dyn Future<Output = ()> + Send>>` |
44 | 30 | help: consider further restricting type parameter `T` with trait `Send`
|
45 | 31 | |
|
46 |
| -23 | async fn publish<T + std::marker::Send>(&self, url: T) {} |
| 32 | +23 | async fn publish<T + std::marker::Send>(&self, _url: T) {} |
47 | 33 | | +++++++++++++++++++
|
0 commit comments