]>
Commit | Line | Data |
---|---|---|
1b1a35ee XL |
1 | // revisions: full min |
2 | #![cfg_attr(full, feature(const_generics))] | |
3 | #![cfg_attr(full, allow(incomplete_features))] | |
f9f354fc XL |
4 | |
5 | trait Baz { | |
6 | type Quaks; | |
7 | } | |
8 | impl Baz for u8 { | |
9 | type Quaks = [u16; 3]; | |
10 | } | |
11 | ||
12 | trait Bar {} | |
13 | impl Bar for [u16; 4] {} | |
14 | impl Bar for [[u16; 3]; 3] {} | |
15 | ||
16 | trait Foo //~ ERROR the trait bound `[u16; 3]: Bar` is not satisfied [E0277] | |
17 | //~^ ERROR the trait bound `[[u16; 3]; 2]: Bar` is not satisfied [E0277] | |
18 | where | |
19 | [<u8 as Baz>::Quaks; 2]: Bar, | |
20 | <u8 as Baz>::Quaks: Bar, | |
21 | { | |
22 | } | |
23 | ||
24 | struct FooImpl; | |
25 | ||
26 | impl Foo for FooImpl {} | |
27 | //~^ ERROR the trait bound `[u16; 3]: Bar` is not satisfied [E0277] | |
28 | //~^^ ERROR the trait bound `[[u16; 3]; 2]: Bar` is not satisfied [E0277] | |
29 | ||
30 | fn f(_: impl Foo) {} | |
31 | //~^ ERROR the trait bound `[u16; 3]: Bar` is not satisfied [E0277] | |
32 | //~^^ ERROR the trait bound `[[u16; 3]; 2]: Bar` is not satisfied [E0277] | |
33 | ||
34 | fn main() { | |
35 | f(FooImpl) | |
36 | } |