diff --git a/src/lib.rs b/src/lib.rs index b9026ff..ce706b5 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -190,7 +190,7 @@ fn build_binary_checker() -> CompositeChecker { /// /// Since `which::Path` implements `Deref` for `std::path::Path`, all methods on `&std::path::Path` /// are also available to `&which::Path` values. -#[derive(Clone, PartialEq)] +#[derive(Clone, PartialEq, Eq)] pub struct Path { inner: path::PathBuf, } @@ -277,8 +277,6 @@ impl AsRef for Path { } } -impl Eq for Path {} - impl PartialEq for Path { fn eq(&self, other: &path::PathBuf) -> bool { self.inner == *other @@ -304,7 +302,7 @@ impl PartialEq for path::PathBuf { /// /// Since `CanonicalPath` implements `Deref` for `std::path::Path`, all methods on /// `&std::path::Path` are also available to `&CanonicalPath` values. -#[derive(Clone, PartialEq)] +#[derive(Clone, PartialEq, Eq)] pub struct CanonicalPath { inner: path::PathBuf, } @@ -411,8 +409,6 @@ impl AsRef for CanonicalPath { } } -impl Eq for CanonicalPath {} - impl PartialEq for CanonicalPath { fn eq(&self, other: &path::PathBuf) -> bool { self.inner == *other