Description
This is a tracking issue for the RFC "Postfix Match" (rust-lang/rfcs#3295).
The feature gate for the issue is #![feature(postfix_match)]
.
About tracking issues
Tracking issues are used to record the overall progress of implementation.
They are also used 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
- Implement the RFC
- Get consensus on design, and if we even want this feature
- Adjust documentation (see instructions on rustc-dev-guide)
- Formatting for new syntax has been added to the Style Guide (nightly-style-procedure)
- Stabilization PR (see instructions on rustc-dev-guide)
Unresolved Questions
-
Lifetime extension
Method call chains will not lifetime extend their arguments. Match statements, however, are notorious for having lifetime extension. It is currently unclear if promoting these use-cases of match would cause more subtle bugs, or if it's negligible -
Postfix macros
One thing that was brought up was that it may be possible to implement this with the Simple postfix macros rfcs#2442 feature. But this feature has not been implemented yet, so that is yet to be seen.
Implementation history
Metadata
Metadata
Assignees
Labels
Type
Projects
Status