aboutsummaryrefslogtreecommitdiff
path: root/src/event.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/event.rs')
-rw-r--r--src/event.rs8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/event.rs b/src/event.rs
index e186cfd..2859ff8 100644
--- a/src/event.rs
+++ b/src/event.rs
@@ -8,7 +8,7 @@ use date::Date;
use errors::EventError;
-#[derive(Debug, Clone, PartialEq, PartialOrd, Eq)]
+#[derive(Debug, Clone, PartialEq, Eq)]
pub struct Event {
pub start: Date,
pub end: End,
@@ -82,6 +82,12 @@ impl Ord for Event {
}
}
+impl PartialOrd for Event {
+ fn partial_cmp(&self, other: &Self) -> Option<Ordering> {
+ Some(self.cmp(other))
+ }
+}
+
impl FromStr for Status {
type Err = EventError;