macro_rules! using {
{ $($p:pat = $v:expr),* ; $b:block } => { ... };
}Expand description
using
ยงUsage
let v = (1, 2);
let v2 = (3, 4);
using!((a, b) = v, (c, d) = v2; {
println!("{} {} {} {}", a, b, c, d)
})equivalent to
let v = (1, 2);
let v2 = (3, 4);
{
let (a, b) = v;
let (c, d) = v2;
{
println!("{} {} {} {}", a, b, c, d)
}
}