common/rust: make SectionRange Ord+Hash

This commit is contained in:
Xiretza 2022-12-15 21:55:16 +01:00
parent 146e0d594c
commit b9b46aab5b

View file

@ -35,7 +35,7 @@ impl fmt::Display for InvalidSectionString {
impl Error for InvalidSectionString {} impl Error for InvalidSectionString {}
/// A range of sections. Always contains at least one element. /// A range of sections. Always contains at least one element.
#[derive(Debug, Clone, Copy, PartialEq, Eq)] #[derive(Debug, Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash)]
pub struct SectionRange<T> { pub struct SectionRange<T> {
start: T, start: T,
end: T, end: T,