summary refs log tree commit diff
path: root/src/test/ui/lifetimes/lifetime-errors/ex3-both-anon-regions-both-are-structs-3.rs
blob: 3b22aef6f324253a30e2bf07a3debc8c78d3981f (plain)
1
2
3
4
5
6
7
8
9
10
struct Ref<'a, 'b> {
    a: &'a u32,
    b: &'b u32,
}

fn foo(mut x: Ref) {
    x.a = x.b; //~ ERROR lifetime mismatch
}

fn main() {}