From f86184869a95199a2e0da844ad257c67f1aac97a Mon Sep 17 00:00:00 2001 From: OGINO Masanori Date: Thu, 31 Jul 2014 07:56:39 +0900 Subject: alloc, arena, test, url, uuid: Elide lifetimes. Signed-off-by: OGINO Masanori --- src/liballoc/rc.rs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'src/liballoc') diff --git a/src/liballoc/rc.rs b/src/liballoc/rc.rs index b31931c6de3..35914aa3541 100644 --- a/src/liballoc/rc.rs +++ b/src/liballoc/rc.rs @@ -226,7 +226,7 @@ impl Rc { /// data is cloned if the reference count is greater than one. #[inline] #[experimental] - pub fn make_unique<'a>(&'a mut self) -> &'a mut T { + pub fn make_unique(&mut self) -> &mut T { // Note that we hold a strong reference, which also counts as // a weak reference, so we only clone if there is an // additional reference of either kind. @@ -247,7 +247,7 @@ impl Rc { impl Deref for Rc { /// Borrow the value contained in the reference-counted box #[inline(always)] - fn deref<'a>(&'a self) -> &'a T { + fn deref(&self) -> &T { &self.inner().value } } @@ -390,7 +390,7 @@ impl Clone for Weak { #[doc(hidden)] trait RcBoxPtr { - fn inner<'a>(&'a self) -> &'a RcBox; + fn inner(&self) -> &RcBox; #[inline] fn strong(&self) -> uint { self.inner().strong.get() } @@ -413,12 +413,12 @@ trait RcBoxPtr { impl RcBoxPtr for Rc { #[inline(always)] - fn inner<'a>(&'a self) -> &'a RcBox { unsafe { &(*self._ptr) } } + fn inner(&self) -> &RcBox { unsafe { &(*self._ptr) } } } impl RcBoxPtr for Weak { #[inline(always)] - fn inner<'a>(&'a self) -> &'a RcBox { unsafe { &(*self._ptr) } } + fn inner(&self) -> &RcBox { unsafe { &(*self._ptr) } } } #[cfg(test)] -- cgit 1.4.1-3-g733a5