diff options
| -rw-r--r-- | src/libcore/slice.rs | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/libcore/slice.rs b/src/libcore/slice.rs index 1a482b75731..3e0b8425573 100644 --- a/src/libcore/slice.rs +++ b/src/libcore/slice.rs @@ -2290,9 +2290,10 @@ impl<A> SlicePartialOrd<A> for [A] } } -impl SlicePartialOrd<u8> for [u8] { - #[inline] - fn partial_compare(&self, other: &[u8]) -> Option<Ordering> { +impl<A> SlicePartialOrd<A> for [A] + where A: Ord +{ + default fn partial_compare(&self, other: &[A]) -> Option<Ordering> { Some(SliceOrd::compare(self, other)) } } |
