diff --git a/src/libcore/slice.rs b/src/libcore/slice.rs index 1a482b75731c1..3e0b842557353 100644 --- a/src/libcore/slice.rs +++ b/src/libcore/slice.rs @@ -2290,9 +2290,10 @@ impl SlicePartialOrd for [A] } } -impl SlicePartialOrd for [u8] { - #[inline] - fn partial_compare(&self, other: &[u8]) -> Option { +impl SlicePartialOrd for [A] + where A: Ord +{ + default fn partial_compare(&self, other: &[A]) -> Option { Some(SliceOrd::compare(self, other)) } }