Impl PartialEq/Ord<str/String> for Path[Buf] by gkoz · Pull Request #31861 · rust-lang/rust (original) (raw)

Sorry for revisiting this: when preparing #31751 I was still assuming that the <str> impls are already there. So currently OsStr can be compared to str and Path cannot. This seems both inconsistent and inconvenient.

I'm likely blind to some drawbacks and/or going over the top with combinations here. Could some of them be replaced with blanket impls for T: AsRef<Path>?

It would help if there was a coordinating issue for libstd trait impls with some goals, dos and don'ts.