]> git.lizzy.rs Git - rust.git/commitdiff
Elide lifetime in Deref doc example
authorFlorian Hartwig <florian.j.hartwig@gmail.com>
Sat, 26 Sep 2015 18:40:22 +0000 (20:40 +0200)
committerFlorian Hartwig <florian.j.hartwig@gmail.com>
Sat, 26 Sep 2015 18:40:22 +0000 (20:40 +0200)
src/libcore/ops.rs

index 350ade22707caac1cafe384ea649ad6737bc624e..582c091091fb2ac800de643d52936b48bb97b7c4 100644 (file)
@@ -1628,7 +1628,7 @@ fn fmt(&self, fmt: &mut fmt::Formatter) -> fmt::Result {
 /// impl<T> Deref for DerefExample<T> {
 ///     type Target = T;
 ///
-///     fn deref<'a>(&'a self) -> &'a T {
+///     fn deref(&self) -> &T {
 ///         &self.value
 ///     }
 /// }