#clone #closures #move #threading #name

clone_all

clone_all!(my,variables,with,long,names);

2 releases

Uses old Rust 2015

0.1.1 Apr 28, 2018
0.1.0 Apr 28, 2018

#29 in #threading

Download history 34/week @ 2024-03-13 116/week @ 2024-03-20 50/week @ 2024-03-27 37/week @ 2024-04-03 28/week @ 2024-04-10 30/week @ 2024-04-17 34/week @ 2024-04-24 20/week @ 2024-05-01 25/week @ 2024-05-08 59/week @ 2024-05-15 113/week @ 2024-05-22 125/week @ 2024-05-29 141/week @ 2024-06-05 172/week @ 2024-06-12 211/week @ 2024-06-19 167/week @ 2024-06-26

716 downloads per month
Used in momen

MIT/Apache

6KB

clone_all

clone_all provides a simple macro to clone all variables passed to it.

For example:

let x: String = "hello world".into();
{
    clone_all!(x);
    something_that_moves(x);
}
// we can still use x, because the x in the scope was cloned.
println!("{}", x);

No runtime deps