Skip to content

Commit 17206a7

Browse files
committed
PinMut::get_mut can also preserve the lifetime
1 parent 84ce206 commit 17206a7

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/libcore/mem.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1141,7 +1141,7 @@ impl<'a, T: ?Sized> PinMut<'a, T> {
11411141
/// the data out of the mutable reference you receive when you call this
11421142
/// function.
11431143
#[unstable(feature = "pin", issue = "49150")]
1144-
pub unsafe fn get_mut<'b>(this: &'b mut PinMut<'a, T>) -> &'b mut T {
1144+
pub unsafe fn get_mut(this: PinMut<'a, T>) -> &'a mut T {
11451145
this.inner
11461146
}
11471147

0 commit comments

Comments
 (0)