From cda660b5fcb74289f7be8414353680db17c4b1bb Mon Sep 17 00:00:00 2001 From: Ivan Tham Date: Wed, 12 Aug 2020 22:17:12 +0800 Subject: [PATCH] Use explicit path link in place for doc in time --- library/std/src/time.rs | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/library/std/src/time.rs b/library/std/src/time.rs index 969c442884d..02161ecb4c8 100644 --- a/library/std/src/time.rs +++ b/library/std/src/time.rs @@ -359,9 +359,7 @@ impl Add for Instant { /// # Panics /// /// This function may panic if the resulting point in time cannot be represented by the - /// underlying data structure. See [`checked_add`] for a version without panic. - /// - /// [`checked_add`]: Instant::checked_add + /// underlying data structure. See [`Instant::checked_add`] for a version without panic. fn add(self, other: Duration) -> Instant { self.checked_add(other).expect("overflow when adding duration to instant") } @@ -525,9 +523,7 @@ impl Add for SystemTime { /// # Panics /// /// This function may panic if the resulting point in time cannot be represented by the - /// underlying data structure. See [`checked_add`] for a version without panic. - /// - /// [`checked_add`]: SystemTime::checked_add + /// underlying data structure. See [`SystemTime::checked_add`] for a version without panic. fn add(self, dur: Duration) -> SystemTime { self.checked_add(dur).expect("overflow when adding duration to instant") }