about summary refs log tree commit diff
path: root/src/libstd
diff options
context:
space:
mode:
Diffstat (limited to 'src/libstd')
-rw-r--r--src/libstd/gc.rs5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/libstd/gc.rs b/src/libstd/gc.rs
index 44988a23070..80f1cbe6cb2 100644
--- a/src/libstd/gc.rs
+++ b/src/libstd/gc.rs
@@ -24,6 +24,7 @@ use default::Default;
 use fmt;
 use hash;
 use kinds::marker;
+use option::Option;
 use ops::Deref;
 use raw;
 
@@ -59,6 +60,10 @@ impl<T: PartialEq + 'static> PartialEq for Gc<T> {
 }
 impl<T: PartialOrd + 'static> PartialOrd for Gc<T> {
     #[inline]
+    fn partial_cmp(&self, other: &Gc<T>) -> Option<Ordering> {
+        (**self).partial_cmp(&**other)
+    }
+    #[inline]
     fn lt(&self, other: &Gc<T>) -> bool { *(*self) < *(*other) }
     #[inline]
     fn le(&self, other: &Gc<T>) -> bool { *(*self) <= *(*other) }