Irregular Usage? Path vs &str? I don't understand

Once again I may be way too wet behind the ears. It looks like Path is supposed to be the same thing for PathBuf as &str is for String. However, I'm already established as notorious for mis-reading the documentation. Please feel welcome to point out the error of my ways. Otherwise, it seems like there is divergence here in usage.

Well, Path corresponds to str. The thing that corresponds to &str is &Path.

But other than that, yes, &Path is to PathBuf as &str is to String.

2 Likes

Ok. I'm getting there guys. Sorry for the foolishness.