diff options
| author | Dzmitry Malyshau <kvarkus@gmail.com> | 2015-04-04 18:54:23 -0400 |
|---|---|---|
| committer | Dzmitry Malyshau <kvarkus@gmail.com> | 2015-04-04 19:01:48 -0400 |
| commit | bc1aef3e7b46db3d3eee4eca80f6462f8a56bbeb (patch) | |
| tree | b56787f557ac9be3162d31e3f2369c5f01854382 /src/liballoc/rc.rs | |
| parent | c1d716ed4b98457fe6b713085ec3598c36aadadd (diff) | |
| download | rust-bc1aef3e7b46db3d3eee4eca80f6462f8a56bbeb.tar.gz rust-bc1aef3e7b46db3d3eee4eca80f6462f8a56bbeb.zip | |
Removed explicit lifetimes for `get_mut`. Fixed the doc test.
Diffstat (limited to 'src/liballoc/rc.rs')
| -rw-r--r-- | src/liballoc/rc.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/liballoc/rc.rs b/src/liballoc/rc.rs index 7cdd4888426..56822cfe28a 100644 --- a/src/liballoc/rc.rs +++ b/src/liballoc/rc.rs @@ -324,7 +324,7 @@ pub fn try_unwrap<T>(rc: Rc<T>) -> Result<T, Rc<T>> { /// ``` #[inline] #[unstable(feature = "alloc")] -pub fn get_mut<'a, T>(rc: &'a mut Rc<T>) -> Option<&'a mut T> { +pub fn get_mut<T>(rc: &mut Rc<T>) -> Option<&mut T> { if is_unique(rc) { let inner = unsafe { &mut **rc._ptr }; Some(&mut inner.value) |
