PinMut::get_mut can also preserve the lifetime
This commit is contained in:
parent
84ce206db6
commit
17206a7e64
@ -1141,7 +1141,7 @@ impl<'a, T: ?Sized> PinMut<'a, T> {
|
||||
/// the data out of the mutable reference you receive when you call this
|
||||
/// function.
|
||||
#[unstable(feature = "pin", issue = "49150")]
|
||||
pub unsafe fn get_mut<'b>(this: &'b mut PinMut<'a, T>) -> &'b mut T {
|
||||
pub unsafe fn get_mut(this: PinMut<'a, T>) -> &'a mut T {
|
||||
this.inner
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user