]> git.proxmox.com Git - rustc.git/blob - src/test/ui/suggestions/restrict-type-argument.stderr
New upstream version 1.62.1+dfsg1
[rustc.git] / src / test / ui / suggestions / restrict-type-argument.stderr
1 error[E0277]: `impl Sync` cannot be sent between threads safely
2 --> $DIR/restrict-type-argument.rs:4:13
3 |
4 LL | is_send(val);
5 | ------- ^^^ `impl Sync` cannot be sent between threads safely
6 | |
7 | required by a bound introduced by this call
8 |
9 note: required by a bound in `is_send`
10 --> $DIR/restrict-type-argument.rs:1:15
11 |
12 LL | fn is_send<T: Send>(val: T) {}
13 | ^^^^ required by this bound in `is_send`
14 help: consider further restricting this bound
15 |
16 LL | fn use_impl_sync(val: impl Sync + std::marker::Send) {
17 | +++++++++++++++++++
18
19 error[E0277]: `S` cannot be sent between threads safely
20 --> $DIR/restrict-type-argument.rs:8:13
21 |
22 LL | is_send(val);
23 | ------- ^^^ `S` cannot be sent between threads safely
24 | |
25 | required by a bound introduced by this call
26 |
27 note: required by a bound in `is_send`
28 --> $DIR/restrict-type-argument.rs:1:15
29 |
30 LL | fn is_send<T: Send>(val: T) {}
31 | ^^^^ required by this bound in `is_send`
32 help: consider further restricting this bound
33 |
34 LL | fn use_where<S>(val: S) where S: Sync + std::marker::Send {
35 | +++++++++++++++++++
36
37 error[E0277]: `S` cannot be sent between threads safely
38 --> $DIR/restrict-type-argument.rs:12:13
39 |
40 LL | is_send(val);
41 | ------- ^^^ `S` cannot be sent between threads safely
42 | |
43 | required by a bound introduced by this call
44 |
45 note: required by a bound in `is_send`
46 --> $DIR/restrict-type-argument.rs:1:15
47 |
48 LL | fn is_send<T: Send>(val: T) {}
49 | ^^^^ required by this bound in `is_send`
50 help: consider further restricting this bound
51 |
52 LL | fn use_bound<S: Sync + std::marker::Send>(val: S) {
53 | +++++++++++++++++++
54
55 error[E0277]: `S` cannot be sent between threads safely
56 --> $DIR/restrict-type-argument.rs:20:13
57 |
58 LL | is_send(val);
59 | ------- ^^^ `S` cannot be sent between threads safely
60 | |
61 | required by a bound introduced by this call
62 |
63 note: required by a bound in `is_send`
64 --> $DIR/restrict-type-argument.rs:1:15
65 |
66 LL | fn is_send<T: Send>(val: T) {}
67 | ^^^^ required by this bound in `is_send`
68 help: consider further restricting this bound
69 |
70 LL | Sync + std::marker::Send
71 | +++++++++++++++++++
72
73 error[E0277]: `S` cannot be sent between threads safely
74 --> $DIR/restrict-type-argument.rs:24:13
75 |
76 LL | is_send(val);
77 | ------- ^^^ `S` cannot be sent between threads safely
78 | |
79 | required by a bound introduced by this call
80 |
81 note: required by a bound in `is_send`
82 --> $DIR/restrict-type-argument.rs:1:15
83 |
84 LL | fn is_send<T: Send>(val: T) {}
85 | ^^^^ required by this bound in `is_send`
86 help: consider further restricting this bound
87 |
88 LL | fn use_bound_and_where<S: Sync + std::marker::Send>(val: S) where S: std::fmt::Debug {
89 | +++++++++++++++++++
90
91 error[E0277]: `S` cannot be sent between threads safely
92 --> $DIR/restrict-type-argument.rs:28:13
93 |
94 LL | is_send(val);
95 | ------- ^^^ `S` cannot be sent between threads safely
96 | |
97 | required by a bound introduced by this call
98 |
99 note: required by a bound in `is_send`
100 --> $DIR/restrict-type-argument.rs:1:15
101 |
102 LL | fn is_send<T: Send>(val: T) {}
103 | ^^^^ required by this bound in `is_send`
104 help: consider restricting type parameter `S`
105 |
106 LL | fn use_unbound<S: std::marker::Send>(val: S) {
107 | +++++++++++++++++++
108
109 error: aborting due to 6 previous errors
110
111 For more information about this error, try `rustc --explain E0277`.