Skip to content

Commit ea7a0c6

Browse files
authored
Rollup merge of rust-lang#129424 - coolreader18:stabilize-pin_as_deref_mut, r=dtolnay
Stabilize `Pin::as_deref_mut()` Tracking issue: closes rust-lang#86918 Stabilizing the following API: ```rust impl<Ptr: DerefMut> Pin<Ptr> { pub fn as_deref_mut(self: Pin<&mut Pin<Ptr>>) -> Pin<&mut Ptr::Target>; } ``` I know that an FCP has not been started yet, but this isn't a very complex stabilization, and I'm hoping this can motivate an FCP to *get* started - this has been pending for a while and it's a very useful function when writing Future impls. r? ``@jonhoo``
2 parents 843c9e9 + bc755bb commit ea7a0c6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

core/src/pin.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1422,7 +1422,7 @@ impl<Ptr: DerefMut> Pin<Ptr> {
14221422
/// move in the future, and this method does not enable the pointee to move. "Malicious"
14231423
/// implementations of `Ptr::DerefMut` are likewise ruled out by the contract of
14241424
/// `Pin::new_unchecked`.
1425-
#[unstable(feature = "pin_deref_mut", issue = "86918")]
1425+
#[stable(feature = "pin_deref_mut", since = "CURRENT_RUSTC_VERSION")]
14261426
#[must_use = "`self` will be dropped if the result is not used"]
14271427
#[inline(always)]
14281428
pub fn as_deref_mut(self: Pin<&mut Pin<Ptr>>) -> Pin<&mut Ptr::Target> {

0 commit comments

Comments
 (0)