Skip to content

Instantly share code, notes, and snippets.

@benaryorg
Created August 19, 2015 13:42
Show Gist options
  • Save benaryorg/b1241563443794733fed to your computer and use it in GitHub Desktop.
Save benaryorg/b1241563443794733fed to your computer and use it in GitHub Desktop.
struct Test
{
x:i32,
y:i32,
z:i32,
}
fn main()
{
let t=Test{x:1,y:2,z:3};
let Test{x:a,y:b,..}=t;
println!("{{{},{},..}}",a,b);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment