]> git.lizzy.rs Git - rust.git/blob - tests/ui/type-alias-impl-trait/not_a_defining_use.stderr
Auto merge of #106503 - cjgillot:remap-nofilter, r=oli-obk
[rust.git] / tests / ui / type-alias-impl-trait / not_a_defining_use.stderr
1 error[E0277]: `T` doesn't implement `Debug`
2   --> $DIR/not_a_defining_use.rs:10:5
3    |
4 LL |     (t, 5i8)
5    |     ^^^^^^^^ `T` cannot be formatted using `{:?}` because it doesn't implement `Debug`
6    |
7    = note: required for `(T, i8)` to implement `Debug`
8 help: consider restricting type parameter `T`
9    |
10 LL | type Two<T: std::fmt::Debug, U> = impl Debug;
11    |           +++++++++++++++++
12
13 error[E0277]: the trait bound `U: Bar` is not satisfied
14   --> $DIR/not_a_defining_use.rs:25:5
15    |
16 LL |     (t, <U as Bar>::FOO)
17    |     ^^^^^^^^^^^^^^^^^^^^ the trait `Bar` is not implemented for `U`
18    |
19 help: consider restricting type parameter `U`
20    |
21 LL | type Two<T, U: Bar> = impl Debug;
22    |              +++++
23
24 error[E0277]: `T` doesn't implement `Debug`
25   --> $DIR/not_a_defining_use.rs:25:5
26    |
27 LL |     (t, <U as Bar>::FOO)
28    |     ^^^^^^^^^^^^^^^^^^^^ `T` cannot be formatted using `{:?}` because it doesn't implement `Debug`
29    |
30    = note: required for `(T, _)` to implement `Debug`
31 help: consider restricting type parameter `T`
32    |
33 LL | type Two<T: std::fmt::Debug, U> = impl Debug;
34    |           +++++++++++++++++
35
36 error: aborting due to 3 previous errors
37
38 For more information about this error, try `rustc --explain E0277`.