Add more derived traits for Path ()

This commit is contained in:
Andrew Jeffery 2021-06-09 11:06:54 +01:00 committed by GitHub
parent 28459f868f
commit b8d282db61
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1,12 +1,12 @@
use std::fmt;
#[derive(Debug, Clone, PartialEq)]
#[derive(Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
pub(crate) enum PathElement {
Key(String),
Index(u32),
}
#[derive(Debug, Clone, PartialEq)]
#[derive(Debug, Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
pub struct Path(Vec<PathElement>);
impl Path {