Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

basename should return a Path #57

Open
davidanthoff opened this issue Nov 28, 2019 · 2 comments
Open

basename should return a Path #57

davidanthoff opened this issue Nov 28, 2019 · 2 comments
Labels
question Further information is requested RFC

Comments

@davidanthoff
Copy link
Contributor

No reason that it returns a String, right?

@rofinn
Copy link
Owner

rofinn commented Nov 29, 2019

basename returns a string because (1) that's what base does and (2) if you think of a path as collection of string segments then basename should be equivalent to returning the last segment. I suppose if we supported indexing then that would be an argument for having basename return a path version of the string.

@rofinn rofinn added help wanted Extra attention is needed RFC and removed help wanted Extra attention is needed labels Apr 9, 2020
@rofinn
Copy link
Owner

rofinn commented Nov 18, 2021

I just thought of another reason why basename should return a String. What should basename(s3path) return? A relative S3Path doesn't really make sense, so would this just return a SystemPath?

@rofinn rofinn added the question Further information is requested label Nov 18, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested RFC
Projects
None yet
Development

No branches or pull requests

2 participants