rust-lang / rust

Empowering everyone to build reliable and efficient software.
https://www.rust-lang.org
Other
98.88k stars 12.78k forks source link

Tracking issue for const `Pin` methods #76654

Open CDirkx opened 4 years ago

CDirkx commented 4 years ago

Constify methods of core::pin::Pin under the feature const_pin.

Implementation: #76655

Methods in const_pin (stable since https://github.com/rust-lang/rust/pull/130136):

Methods in const_pin2:

The const_pin2 methods will need #[rustc_allow_const_fn_unstable(const_precise_live_drops)] but that has been approved here.

ecstatic-morse commented 4 years ago

As you mention in #76655 PR, the implementation of some of these methods depends on the unstable const_precise_live_drops feature. Future readers should check the status of that feature before attempting to stabilize these. #76618 will ensure that this does not happen by accident.

RalfJung commented 1 month ago

@dtolnay wrote

I'd be happy to take a separate PR for the const-stabilizing of into_inner + into_inner_unchecked. Procedurally I think a fresh FCP would be required.

So, let's get that train rolling -- @rust-lang/libs-api can we const-stabilize the const_pin2 feature gate, which guards Pin::into_inner and Pin::into_inner_unchecked (already stable outside const)?

dtolnay commented 1 month ago

@rfcbot fcp merge

rfcbot commented 1 month ago

Team member @dtolnay has proposed to merge this. The next step is review by the rest of the tagged team members:

No concerns currently listed.

Once a majority of reviewers approve (and at most 2 approvals are outstanding), this will enter its final comment period. If you spot a major issue that hasn't been raised at any point in this process, please speak up!

See this document for info about what commands tagged team members can give me.

tgross35 commented 1 month ago

can we const-stabilize the const_pin2 feature gate, which guards Pin::into_inner and Pin::into_inner_unchecked

Since this will likely be the same release cycle, the const_pin2 items can probably just be grouped back into const_pin.

tgross35 commented 2 weeks ago

@Amanieu @BurntSushi @m-ou-se could this get one more check? So we avoid splitting const_pin if fcp doesn't make the next branch.

rfcbot commented 2 weeks ago

:bell: This is now entering its final comment period, as per the review above. :bell:

rfcbot commented 1 week ago

The final comment period, with a disposition to merge, as per the review above, is now complete.

As the automated representative of the governance process, I would like to thank the author for their work and everyone else who contributed.

This will be merged soon.

RalfJung commented 1 week ago

Stabilization PR is up at https://github.com/rust-lang/rust/pull/133127