1
Fork 0
rust/compiler/rustc_feature/src
Matthias Krüger 783778c631
Rollup merge of #121619 - RossSmyth:pfix_match, r=petrochenkov
Experimental feature postfix match

This has a basic experimental implementation for the RFC postfix match (rust-lang/rfcs#3295, #121618). [Liaison is](423301844) ```@scottmcm``` with the lang team's [experimental feature gate process](https://github.com/rust-lang/lang-team/blob/master/src/how_to/experiment.md).

This feature has had an RFC for a while, and there has been discussion on it for a while. It would probably be valuable to see it out in the field rather than continue discussing it. This feature also allows to see how popular postfix expressions like this are for the postfix macros RFC, as those will take more time to implement.

It is entirely implemented in the parser, so it should be relatively easy to remove if needed.

This PR is split in to 5 commits to ease review.

1. The implementation of the feature & gating.
2. Add a MatchKind field, fix uses, fix pretty.
3. Basic rustfmt impl, as rustfmt crashes upon seeing this syntax without a fix.
4. Add new MatchSource to HIR for Clippy & other HIR consumers
2024-03-22 11:36:58 +01:00
..
accepted.rs branch 1.78: replace-version-placeholder 2024-03-19 19:27:24 -04:00
builtin_attrs.rs Change syntax of the never type attribute thingy 2024-03-21 19:47:46 +00:00
lib.rs Change only_local to enum type and change the macros to always require a variant of that enum. 2024-03-19 20:13:40 +08:00
removed.rs branch 1.78: replace-version-placeholder 2024-03-19 19:27:24 -04:00
tests.rs tidy: Re-enable check for inline unit tests 2020-12-12 19:18:44 +03:00
unstable.rs Rollup merge of #121619 - RossSmyth:pfix_match, r=petrochenkov 2024-03-22 11:36:58 +01:00