]> git.lizzy.rs Git - rust.git/blob - tests/ui/generic-associated-types/parameter_number_and_kind.rs
Rollup merge of #103702 - WaffleLapkin:lift-sized-bounds-from-pointer-methods-where...
[rust.git] / tests / ui / generic-associated-types / parameter_number_and_kind.rs
1 #![feature(associated_type_defaults)]
2
3 trait Foo {
4     type A<'a>;
5     type B<'a, 'b>;
6     type C;
7     type D<T>;
8     type E<'a, T>;
9     // Test parameters in default values
10     type FOk<T> = Self::E<'static, T>;
11     type FErr1 = Self::E<'static, 'static>;
12     //~^ ERROR this associated type takes 1 lifetime argument but 2 lifetime arguments were supplied
13     //~| ERROR this associated type takes 1
14     type FErr2<T> = Self::E<'static, T, u32>;
15     //~^ ERROR this associated type takes 1
16 }
17
18 fn main() {}