2025-04-09 17:25:46 +00:00
|
|
|
error[E0277]: the trait bound `<T as Foo2>::Assoc2: Bar` is not satisfied
|
2024-01-26 15:26:03 +01:00
|
|
|
--> $DIR/recursive-self-normalization-2.rs:15:17
|
|
|
|
|
|
|
|
|
|
|
LL | needs_bar::<T::Assoc1>();
|
2025-04-09 17:25:46 +00:00
|
|
|
| ^^^^^^^^^ the trait `Bar` is not implemented for `<T as Foo2>::Assoc2`
|
2023-03-29 15:36:17 +02:00
|
|
|
|
|
|
|
|
|
note: required by a bound in `needs_bar`
|
2023-12-08 17:29:48 +01:00
|
|
|
--> $DIR/recursive-self-normalization-2.rs:12:17
|
2023-03-29 15:36:17 +02:00
|
|
|
|
|
|
|
|
|
LL | fn needs_bar<S: Bar>() {}
|
|
|
|
|
| ^^^ required by this bound in `needs_bar`
|
2025-02-27 11:57:05 +01:00
|
|
|
help: consider further restricting the associated type
|
2024-01-10 16:30:07 +00:00
|
|
|
|
|
2025-04-09 17:25:46 +00:00
|
|
|
LL | fn test<T: Foo1<Assoc1 = <T as Foo2>::Assoc2> + Foo2<Assoc2 = <T as Foo1>::Assoc1>>() where <T as Foo2>::Assoc2: Bar {
|
2025-02-27 11:57:05 +01:00
|
|
|
| ++++++++++++++++++++++++++++++
|
2024-01-10 16:30:07 +00:00
|
|
|
|
2025-02-27 11:57:05 +01:00
|
|
|
error: aborting due to 1 previous error
|
2023-03-27 21:48:43 +00:00
|
|
|
|
2025-02-27 11:57:05 +01:00
|
|
|
For more information about this error, try `rustc --explain E0277`.
|