blob: 02c024341724a9d68e142de0f80a86502d7ff732 [file]
error[E0308]: mismatched types
--> $DIR/param-env-shadowing-gat.rs:14:5
|
LL | fn foo<T: Trait>(x: T::Assoc<T>) -> u32 {
| --- expected `u32` because of return type
LL | x
| ^ expected `u32`, found associated type
|
= note: expected type `u32`
found associated type `<T as Trait>::Assoc<T>`
help: consider constraining the associated type `<T as Trait>::Assoc<T>` to `u32`
|
LL | fn foo<T: Trait<Assoc<T> = u32>>(x: T::Assoc<T>) -> u32 {
| ++++++++++++++++
error: aborting due to 1 previous error
For more information about this error, try `rustc --explain E0308`.