From 957d51aecb3eb4960129b38b147cff0b8d0fae5c Mon Sep 17 00:00:00 2001 From: Tobias Bucher Date: Tue, 25 Apr 2017 01:02:59 +0200 Subject: [PATCH] Fix a copy-paste error in `Instant::sub_duration` Fixes #41514. --- src/libstd/sys/unix/time.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libstd/sys/unix/time.rs b/src/libstd/sys/unix/time.rs index a08cec38f732d..a1ad94872de5c 100644 --- a/src/libstd/sys/unix/time.rs +++ b/src/libstd/sys/unix/time.rs @@ -157,7 +157,7 @@ mod inner { pub fn sub_duration(&self, other: &Duration) -> Instant { Instant { t: self.t.checked_sub(dur2intervals(other)) - .expect("overflow when adding duration to instant"), + .expect("overflow when subtracting duration from instant"), } } }