diff options
| author | Dmitry Gritsay <unseductable@gmail.com> | 2016-11-01 23:18:02 +0200 |
|---|---|---|
| committer | Dmitry Gritsay <unseductable@gmail.com> | 2016-11-01 23:18:02 +0200 |
| commit | 7d5b788edffc447946e8c27d683e8604b59443c5 (patch) | |
| tree | 65139231b1580f7d89f95983de26c0e8dbf27aa6 /src/libcore | |
| parent | ea4b94dab0d526135dd658d3a314cc5462d439b0 (diff) | |
Elide lifetimes in DerefMut documentation
- Elide lifetimes to increase the readability of `DerefMut` examples
Diffstat (limited to 'src/libcore')
| -rw-r--r-- | src/libcore/ops.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/libcore/ops.rs b/src/libcore/ops.rs index 62aa57bbbbf..5c36d337799 100644 --- a/src/libcore/ops.rs +++ b/src/libcore/ops.rs @@ -2484,13 +2484,13 @@ impl<'a, T: ?Sized> Deref for &'a mut T { /// impl<T> Deref for DerefMutExample<T> { /// type Target = T; /// -/// fn deref<'a>(&'a self) -> &'a T { +/// fn deref(&self) -> &T { /// &self.value /// } /// } /// /// impl<T> DerefMut for DerefMutExample<T> { -/// fn deref_mut<'a>(&'a mut self) -> &'a mut T { +/// fn deref_mut(&mut self) -> &mut T { /// &mut self.value /// } /// } |
