]> git.lizzy.rs Git - rust.git/blob - tests/ui/associated-types/issue-65774-1.stderr
Rollup merge of #106427 - mejrs:translation_errors, r=davidtwco
[rust.git] / tests / ui / associated-types / issue-65774-1.stderr
1 error[E0277]: the trait bound `T: MyDisplay` is not satisfied
2   --> $DIR/issue-65774-1.rs:10:33
3    |
4 LL |     type MpuConfig: MyDisplay = T;
5    |                                 ^ the trait `MyDisplay` is not implemented for `T`
6    |
7    = help: the trait `MyDisplay` is implemented for `&'a mut T`
8 note: required by a bound in `MPU::MpuConfig`
9   --> $DIR/issue-65774-1.rs:10:21
10    |
11 LL |     type MpuConfig: MyDisplay = T;
12    |                     ^^^^^^^^^ required by this bound in `MPU::MpuConfig`
13
14 error[E0277]: the trait bound `T: MyDisplay` is not satisfied
15   --> $DIR/issue-65774-1.rs:44:76
16    |
17 LL |         let closure = |config: &mut <S as MPU>::MpuConfig| writer.my_write(&config);
18    |                                                                            ^^^^^^^ the trait `MyDisplay` is not implemented for `T`
19    |
20    = help: the trait `MyDisplay` is implemented for `&'a mut T`
21 note: required for `&mut T` to implement `MyDisplay`
22   --> $DIR/issue-65774-1.rs:5:24
23    |
24 LL | impl<'a, T: MyDisplay> MyDisplay for &'a mut T { }
25    |                        ^^^^^^^^^     ^^^^^^^^^
26    = note: required for the cast from `&mut T` to the object type `dyn MyDisplay`
27
28 error: aborting due to 2 previous errors
29
30 For more information about this error, try `rustc --explain E0277`.