rust/tests/ui/associated-type-bounds/issue-102335-ty.rs

20 lines
491 B
Rust

trait T {
type A: S<C<i32 = u32> = ()>; // Just one erroneous equality constraint
//~^ ERROR associated type bindings are not allowed here
//~| ERROR associated type bindings are not allowed here
}
trait T2 {
type A: S<C<i32 = u32, X = i32> = ()>; // More than one erroneous equality constraints
//~^ ERROR associated type bindings are not allowed here
//~| ERROR associated type bindings are not allowed here
}
trait Q {}
trait S {
type C: Q;
}
fn main() {}