]>
Commit | Line | Data |
---|---|---|
29967ef6 XL |
1 | // Check that we validate associated type bounds on super traits for trait |
2 | // objects | |
3 | ||
4 | trait Super { | |
5 | type Y: Clone; | |
6 | } | |
7 | ||
8 | trait X: Super {} | |
9 | ||
10 | fn f<T: X + ?Sized>() { | |
11 | None::<T::Y>.clone(); | |
12 | } | |
13 | ||
14 | fn main() { | |
15 | f::<dyn X<Y = str>>(); | |
16 | //~^ ERROR the trait bound `str: Clone` is not satisfied | |
17 | } |