blob: e33528ac59e68293b8110f65dd93795be2357eee (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
struct A {
b: B,
}
#[derive(Clone)]
struct B;
fn foo(_: A) {}
fn bar(mut a: A) -> B {
a.b = B;
foo(a);
a.b.clone()
//~^ ERROR borrow of moved value
}
fn main() {}
|