fork/rust
git clone https://git.julia.blue/fork/rust
3bcad65fbf6
master
1// run-rustfix 2#![allow(unused)] 3struct S {f:String} 4impl Drop for S { 5 fn drop(&mut self) { println!("{}", self.f); } 6} 7 8fn move_in_match() { 9 match (S {f:"foo".to_string()}) { 10 //~^ ERROR [E0509] 11 S {f:ref _s} => {} 12 } 13} 14 15fn move_in_let() { 16 let S {f:ref _s} = S {f:"foo".to_string()}; 17 //~^ ERROR [E0509] 18} 19 20fn move_in_fn_arg(S {f:ref _s}: S) { 21 //~^ ERROR [E0509] 22} 23 24fn main() {}