about summary refs log tree commit diff
path: root/tests/codegen/patchable-function-entry
diff options
context:
space:
mode:
authorMatthias Krüger <matthias.krueger@famsik.de>2024-03-21 12:05:05 +0100
committerGitHub <noreply@github.com>2024-03-21 12:05:05 +0100
commit0867025cc8b0a30e44527595432d27af68ea734b (patch)
treed823b6ef79ec4b7a11ce9ce3a4530e92101d479a /tests/codegen/patchable-function-entry
parentdf8ac8f1d74cffb96a93ae702d16e224f5b9ee8c (diff)
parent120d3570aa467c287814fe3edb9003920d8232aa (diff)
downloadrust-0867025cc8b0a30e44527595432d27af68ea734b.tar.gz
rust-0867025cc8b0a30e44527595432d27af68ea734b.zip
Rollup merge of #122222 - Nadrieril:deref-pat-feature-gate, r=compiler-errors
deref patterns: bare-bones feature gate and typechecking

I am restarting the deref patterns experimentation. This introduces a feature gate under the lang-team [experimental feature](https://github.com/rust-lang/lang-team/blob/master/src/how_to/experiment.md) process, with [````@cramertj```` as lang-team liaison](https://github.com/rust-lang/lang-team/issues/88) (it's been a while though, you still ok with this ````@cramertj?).```` Tracking issue: https://github.com/rust-lang/rust/issues/87121.

This is the barest-bones implementation I could think of:
- explicit syntax, reusing `box <pat>` because that saves me a ton of work;
- use `Deref` as a marker trait (instead of a yet-to-design `DerefPure`);
- no support for mutable patterns with `DerefMut` for now;
- MIR lowering will come in the next PR. It's the trickiest part.

My goal is to let us figure out the MIR lowering part, which might take some work. And hopefully get something working for std types soon.

This is in large part salvaged from ````@fee1-dead's```` https://github.com/rust-lang/rust/pull/119467.

r? ````@compiler-errors````
Diffstat (limited to 'tests/codegen/patchable-function-entry')
0 files changed, 0 insertions, 0 deletions