summary refs log tree commit diff
path: root/src/libstd
diff options
context:
space:
mode:
authorCorey Farwell <coreyf@rwell.org>2017-04-25 23:05:58 -0400
committerGitHub <noreply@github.com>2017-04-25 23:05:58 -0400
commit997593f16c11efff839be7498807995240b8ada5 (patch)
treee80004eb235350aab7a6dab64b8dee69b44e2f2f /src/libstd
parent41933c315c2339cecad799e2d2a247a2b50122ca (diff)
parent957d51aecb3eb4960129b38b147cff0b8d0fae5c (diff)
downloadrust-997593f16c11efff839be7498807995240b8ada5.tar.gz
rust-997593f16c11efff839be7498807995240b8ada5.zip
Rollup merge of #41518 - tbu-:pr_fix_cp_error, r=sfackler
Fix a copy-paste error in `Instant::sub_duration`

Fixes #41514.
Diffstat (limited to 'src/libstd')
-rw-r--r--src/libstd/sys/unix/time.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libstd/sys/unix/time.rs b/src/libstd/sys/unix/time.rs
index a08cec38f73..a1ad94872de 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"),
             }
         }
     }