diff options
| author | bors <bors@rust-lang.org> | 2014-12-19 16:02:31 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2014-12-19 16:02:31 +0000 |
| commit | 95c2ed31aeb66b2662933200dbfd661a573b1f49 (patch) | |
| tree | 3e397ee769c09211083f8aa12377e41104575f7f /src/libstd/time | |
| parent | bd90b936d73c0ea2c261cd8e7b9c43764cb2da05 (diff) | |
| parent | f975b10310b2f38a5ac1e50f30778b85ed963849 (diff) | |
auto merge of #19867 : japaric/rust/deriving-copy, r=acrichto
r? @alexcrichton
Diffstat (limited to 'src/libstd/time')
| -rw-r--r-- | src/libstd/time/duration.rs | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/src/libstd/time/duration.rs b/src/libstd/time/duration.rs index 85ed27853c4..7cb14e8e4bc 100644 --- a/src/libstd/time/duration.rs +++ b/src/libstd/time/duration.rs @@ -13,7 +13,6 @@ #![experimental] use {fmt, i64}; -use kinds::Copy; use ops::{Add, Sub, Mul, Div, Neg, FnOnce}; use option::Option; use option::Option::{Some, None}; @@ -47,7 +46,7 @@ macro_rules! try_opt { /// ISO 8601 time duration with nanosecond precision. /// This also allows for the negative duration; see individual methods for details. -#[deriving(Clone, PartialEq, Eq, PartialOrd, Ord)] +#[deriving(Clone, Copy, PartialEq, Eq, PartialOrd, Ord)] pub struct Duration { secs: i64, nanos: i32, // Always 0 <= nanos < NANOS_PER_SEC @@ -65,8 +64,6 @@ pub const MAX: Duration = Duration { nanos: (i64::MAX % MILLIS_PER_SEC) as i32 * NANOS_PER_MILLI }; -impl Copy for Duration {} - impl Duration { /// Makes a new `Duration` with given number of weeks. /// Equivalent to `Duration::seconds(weeks * 7 * 24 * 60 * 60), with overflow checks. |
