rust/tests/ui/const-generics/min_const_generics/forbid-self-no-normalize.rs
2023-01-11 09:32:08 +00:00

16 lines
295 B
Rust

trait AlwaysApplicable {
type Assoc;
}
impl<T: ?Sized> AlwaysApplicable for T {
type Assoc = usize;
}
trait BindsParam<T> {
type ArrayTy;
}
impl<T> BindsParam<T> for <T as AlwaysApplicable>::Assoc {
type ArrayTy = [u8; Self::MAX]; //~ ERROR generic `Self` types
}
fn main() {}