]> git.proxmox.com Git - rustc.git/blob - src/test/ui/associated-types/defaults-suitability.stderr
New upstream version 1.44.1+dfsg1
[rustc.git] / src / test / ui / associated-types / defaults-suitability.stderr
1 error[E0277]: the trait bound `NotClone: std::clone::Clone` is not satisfied
2 --> $DIR/defaults-suitability.rs:15:14
3 |
4 LL | trait Tr {
5 | -------- required by `Tr`
6 LL | type Ty: Clone = NotClone;
7 | ^^^^^ the trait `std::clone::Clone` is not implemented for `NotClone`
8
9 error[E0277]: the trait bound `NotClone: std::clone::Clone` is not satisfied
10 --> $DIR/defaults-suitability.rs:20:27
11 |
12 LL | trait Tr2 where Self::Ty: Clone {
13 | --------------------------^^^^^
14 | | |
15 | | the trait `std::clone::Clone` is not implemented for `NotClone`
16 | required by `Tr2`
17
18 error[E0277]: the trait bound `T: std::clone::Clone` is not satisfied
19 --> $DIR/defaults-suitability.rs:33:15
20 |
21 LL | trait Foo<T> {
22 | ------------ required by `Foo`
23 LL | type Bar: Clone = Vec<T>;
24 | ^^^^^ the trait `std::clone::Clone` is not implemented for `T`
25 |
26 = note: required because of the requirements on the impl of `std::clone::Clone` for `std::vec::Vec<T>`
27 help: consider restricting type parameter `T`
28 |
29 LL | trait Foo<T: std::clone::Clone> {
30 | ^^^^^^^^^^^^^^^^^^^
31
32 error[E0277]: the trait bound `(): Foo<Self>` is not satisfied
33 --> $DIR/defaults-suitability.rs:39:17
34 |
35 LL | trait Bar: Sized {
36 | ---------------- required by `Bar`
37 LL | // `(): Foo<Self>` might hold for some possible impls but not all.
38 LL | type Assoc: Foo<Self> = ();
39 | ^^^^^^^^^ the trait `Foo<Self>` is not implemented for `()`
40
41 error[E0277]: the trait bound `NotClone: IsU8<NotClone>` is not satisfied
42 --> $DIR/defaults-suitability.rs:59:18
43 |
44 LL | / trait D where
45 LL | | Vec<Self::Assoc>: Clone,
46 LL | |
47 LL | | Self::Assoc: IsU8<Self::Assoc>,
48 | | ^^^^^^^^^^^^^^^^^ the trait `IsU8<NotClone>` is not implemented for `NotClone`
49 ... |
50 LL | | type Assoc = NotClone;
51 LL | | }
52 | |_- required by `D`
53
54 error[E0277]: the trait bound `bool: IsU8<NotClone>` is not satisfied
55 --> $DIR/defaults-suitability.rs:61:11
56 |
57 LL | / trait D where
58 LL | | Vec<Self::Assoc>: Clone,
59 LL | |
60 LL | | Self::Assoc: IsU8<Self::Assoc>,
61 LL | |
62 LL | | bool: IsU8<Self::Assoc>,
63 | | ^^^^^^^^^^^^^^^^^ the trait `IsU8<NotClone>` is not implemented for `bool`
64 ... |
65 LL | | type Assoc = NotClone;
66 LL | | }
67 | |_- required by `D`
68
69 error[E0277]: the trait bound `NotClone: std::clone::Clone` is not satisfied
70 --> $DIR/defaults-suitability.rs:57:23
71 |
72 LL | / trait D where
73 LL | | Vec<Self::Assoc>: Clone,
74 | | ^^^^^ the trait `std::clone::Clone` is not implemented for `NotClone`
75 LL | |
76 LL | | Self::Assoc: IsU8<Self::Assoc>,
77 ... |
78 LL | | type Assoc = NotClone;
79 LL | | }
80 | |_- required by `D`
81 |
82 = note: required because of the requirements on the impl of `std::clone::Clone` for `std::vec::Vec<NotClone>`
83
84 error[E0277]: the trait bound `<Self as Foo2<T>>::Baz: std::clone::Clone` is not satisfied
85 --> $DIR/defaults-suitability.rs:72:15
86 |
87 LL | trait Foo2<T> {
88 | -------------- help: consider further restricting the associated type: `where <Self as Foo2<T>>::Baz: std::clone::Clone`
89 | |
90 | required by `Foo2`
91 LL | type Bar: Clone = Vec<Self::Baz>;
92 | ^^^^^ the trait `std::clone::Clone` is not implemented for `<Self as Foo2<T>>::Baz`
93 |
94 = note: required because of the requirements on the impl of `std::clone::Clone` for `std::vec::Vec<<Self as Foo2<T>>::Baz>`
95
96 error[E0277]: the trait bound `<Self as Foo25<T>>::Baz: std::clone::Clone` is not satisfied
97 --> $DIR/defaults-suitability.rs:81:15
98 |
99 LL | trait Foo25<T: Clone> {
100 | ---------------------- help: consider further restricting the associated type: `where <Self as Foo25<T>>::Baz: std::clone::Clone`
101 | |
102 | required by `Foo25`
103 LL | type Bar: Clone = Vec<Self::Baz>;
104 | ^^^^^ the trait `std::clone::Clone` is not implemented for `<Self as Foo25<T>>::Baz`
105 |
106 = note: required because of the requirements on the impl of `std::clone::Clone` for `std::vec::Vec<<Self as Foo25<T>>::Baz>`
107
108 error[E0277]: the trait bound `T: std::clone::Clone` is not satisfied
109 --> $DIR/defaults-suitability.rs:90:16
110 |
111 LL | / trait Foo3<T> where
112 LL | | Self::Bar: Clone,
113 LL | | Self::Baz: Clone,
114 | | ^^^^^ the trait `std::clone::Clone` is not implemented for `T`
115 LL | |
116 ... |
117 LL | | type Baz = T;
118 LL | | }
119 | |_- required by `Foo3`
120 |
121 help: consider further restricting type parameter `T`
122 |
123 LL | Self::Baz: Clone, T: std::clone::Clone
124 | ^^^^^^^^^^^^^^^^^^^^^^
125
126 error[E0277]: the size for values of type `[u8]` cannot be known at compilation time
127 --> $DIR/defaults-suitability.rs:27:5
128 |
129 LL | type Ty = Vec<[u8]>;
130 | ^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
131 |
132 ::: $SRC_DIR/liballoc/vec.rs:LL:COL
133 |
134 LL | pub struct Vec<T> {
135 | - required by this bound in `std::vec::Vec`
136 |
137 = help: the trait `std::marker::Sized` is not implemented for `[u8]`
138 = note: to learn more, visit <https://doc.rust-lang.org/book/ch19-04-advanced-types.html#dynamically-sized-types-and-the-sized-trait>
139
140 error: aborting due to 11 previous errors
141
142 For more information about this error, try `rustc --explain E0277`.