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