Closed
Description
RBE doesn't mention PathBuf anywhere. A programmer at my work asked:
"Why PathBuf? Just why generally. I started out using it where I thought it made sense, now I just pass &str. Things like .extension() returning an OsStr mean I just use .ends_with() instead which sort of does the same thing (but not always)"
Steve suggested mentioning that between String
is to str
as PathBuf
is to Path
.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment