use Eq::eq instead of Iterator::eq implementation

This commit is contained in:
The8472 2021-07-06 00:46:40 +02:00
parent 6e9b3696d4
commit 5dcfec332c

View File

@ -2686,7 +2686,7 @@ impl fmt::Display for Display<'_> {
impl cmp::PartialEq for Path {
#[inline]
fn eq(&self, other: &Path) -> bool {
self.components().eq(other.components())
self.components() == other.components()
}
}