e74abb32 XL |
1 | trait Trait {} |
2 | |
3 | struct S; |
4 | |
5 | impl<'a> Trait for &'a mut S {} |
6 | |
7 | fn foo<X: Trait>(_: X) {} |
8 | |
9 | |
10 | fn main() { |
11 | let s = S; |
12 | foo(&s); //~ ERROR the trait bound `&S: Trait` is not satisfied |
13 | foo(s); //~ ERROR the trait bound `S: Trait` is not satisfied |
14 | } |