Closed
Description
I'm not sure if it's less efficient to do:
let mut (a, b, c, d) = (self.x[0], self.x[1], self.x[2], self.x[3]);
Than:
let mut a = self.x[0];
let mut b = self.x[1];
let mut c = self.x[2];
let mut d = self.x[3];
But I find the former a lot easier to type in some cases. It'd be nice to know if destructuring of this kind is a valid use of tuple unpacking in Rust.
It'd also be nice if the following was legal:
let (self.x[0], self.x[1], self.x[2], self.x[3]) = (a, b, c, d);
Right now the above dies with the following error:
expected `,` but found `.`
Metadata
Metadata
Assignees
Labels
No labels