Closed
Description
This is a tracking issue for the RFC "Destructuring assignment" (rust-lang/rfcs#2909).
The feature gate for the issue is #![feature(destructuring_assignment)]
.
About tracking issues
Tracking issues are used to record the overall progress of implementation.
They are also uses as hubs connecting to other relevant issues, e.g., bugs or open design questions.
A tracking issue is however not meant for large scale discussion, questions, or bug reports about a feature.
Instead, open a dedicated issue for the specific matter and add the relevant feature gate label.
Steps
- Open a pull request: Implement destructuring assignment #71156
- Tuples (Implement destructuring assignment for tuples #78748)
- Structs and slices (Implement destructuring assignment for structs and slices #78836)
-
_
expressions (Make_
an expression, to discard values in destructuring assignments #79016)
- Open an RFC: Destructuring assignment rfcs#2909.
- Adjust documentation (see instructions on rustc-dev-guide)
- Stabilization PR (Stabilize
destructuring_assignment
#90521)
Implementation history
The initial implementation was carried out in three steps by @fanzier (split out from an initial implementation, #71156):
- Implementing destructuring support for tuples: Implement destructuring assignment for tuples #78748
- Implementing destructuring support for structs and slices: Implement destructuring assignment for structs and slices #78836
- Implementing destructuring support for
_
expressions: Make_
an expression, to discard values in destructuring assignments #79016