blob: 6b879af5aecdac47ebb07c0a0a3b9c093d570335 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
// run-pass
struct Foo<'a> {
x: &'a i32
}
impl<'a> Foo<'a> {
fn method(&mut self, _: &i32) {
}
}
fn main() {
let a = &mut Foo { x: &22 };
Foo::method(a, a.x);
}
|