1 error: `impl` associated type signature for `A` doesn't match `trait` associated type signature
2 --> $DIR/impl_bounds.rs:15:5
4 LL | type A<'a> where Self: 'a;
5 | -------------------------- expected
7 LL | type A<'a> = (&'a ()) where Self: 'static;
8 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ found
10 error: `impl` associated type signature for `B` doesn't match `trait` associated type signature
11 --> $DIR/impl_bounds.rs:17:5
13 LL | type B<'a, 'b> where 'a: 'b;
14 | ---------------------------- expected
16 LL | type B<'a, 'b> = (&'a(), &'b ()) where 'b: 'a;
17 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ found
19 error[E0478]: lifetime bound not satisfied
20 --> $DIR/impl_bounds.rs:17:22
22 LL | type B<'a, 'b> where 'a: 'b;
23 | ---------------------------- definition of `B` from trait
25 LL | type B<'a, 'b> = (&'a(), &'b ()) where 'b: 'a;
26 | ^^^^^^^^^^^^^^^ - help: try copying this clause from the trait: `, 'a: 'b`
28 note: lifetime parameter instantiated with the lifetime `'a` as defined here
29 --> $DIR/impl_bounds.rs:17:12
31 LL | type B<'a, 'b> = (&'a(), &'b ()) where 'b: 'a;
33 note: but lifetime parameter must outlive the lifetime `'b` as defined here
34 --> $DIR/impl_bounds.rs:17:16
36 LL | type B<'a, 'b> = (&'a(), &'b ()) where 'b: 'a;
39 error[E0277]: the trait bound `T: Copy` is not satisfied
40 --> $DIR/impl_bounds.rs:20:5
42 LL | type C = String where Self: Copy;
43 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `Copy` is not implemented for `T`
45 note: required because of the requirements on the impl of `Copy` for `Fooy<T>`
46 --> $DIR/impl_bounds.rs:11:10
48 LL | #[derive(Copy, Clone)]
50 note: the requirement `Fooy<T>: Copy` appears on the associated impl type `C` but not on the corresponding associated trait type
51 --> $DIR/impl_bounds.rs:7:5
56 LL | type C where Self: Clone;
57 | ^^^^^^^^^^^^^^^^^^^^^^^^^ this trait associated type doesn't have the requirement `Fooy<T>: Copy`
58 = note: this error originates in the derive macro `Copy` (in Nightly builds, run with -Z macro-backtrace for more info)
59 help: consider restricting type parameter `T`
61 LL | impl<T: std::marker::Copy> Foo for Fooy<T> {
64 error[E0277]: the trait bound `T: Copy` is not satisfied
65 --> $DIR/impl_bounds.rs:22:24
67 LL | fn d() where Self: Copy {}
68 | ^^^^ the trait `Copy` is not implemented for `T`
70 note: required because of the requirements on the impl of `Copy` for `Fooy<T>`
71 --> $DIR/impl_bounds.rs:11:10
73 LL | #[derive(Copy, Clone)]
75 note: the requirement `Fooy<T>: Copy` appears on the impl method `d` but not on the corresponding trait method
76 --> $DIR/impl_bounds.rs:8:8
81 LL | fn d() where Self: Clone;
82 | ^ this trait method doesn't have the requirement `Fooy<T>: Copy`
83 = note: this error originates in the derive macro `Copy` (in Nightly builds, run with -Z macro-backtrace for more info)
84 help: consider restricting type parameter `T`
86 LL | impl<T: std::marker::Copy> Foo for Fooy<T> {
89 error: aborting due to 5 previous errors
91 Some errors have detailed explanations: E0277, E0478.
92 For more information about an error, try `rustc --explain E0277`.