"the trait bound is not satisfied" when using traits from associated type #138119
Labels
A-associated-items
Area: Associated items (types, constants & functions)
A-trait-system
Area: Trait system
C-bug
Category: This is a bug.
T-types
Relevant to the types team, which will review and decide on the PR/issue.
I tried this code:
Playground link: https://play.rust-lang.org/?version=stable&mode=debug&edition=2024&gist=95dd0d2d1db3207a2a4c1b3ff5ec977a
I expected to see this happen: It should compile correctly, since
Trait2::Ty2
implementsDefault + Into<u8>
.Instead, this happened:
Builds correctly if I remove
Ty2 = Self::Ty1
fromTrait3::Ty3
or addDefault + Into<u8>
toTrait1::Ty1
Meta
rustc --version --verbose
:The text was updated successfully, but these errors were encountered: