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

add derived Copy impls for Dir, DirEntry, and File #74

Closed
wants to merge 1 commit into from

Conversation

jbr
Copy link

@jbr jbr commented Dec 23, 2021

As this only adds behavior, this is semver-patch

@Michael-F-Bryan
Copy link
Owner

I'm reluctant to derive Copy for these types because it means we can't add compression (#14) later on without causing breakage.

Is there a particular use case you had in mind that requires Dir: Copy?

@jbr
Copy link
Author

jbr commented Dec 24, 2021

In this case, I was mostly just surprised they weren't already Copy. I was doing a bunch of cloning to work around #73 when I ran into this.

@Michael-F-Bryan
Copy link
Owner

I'm curious why you needed to clone the File handles or were running into lifetime issues. Do you have any simple examples for where the lack of 'static lifetimes causes problems?

@Michael-F-Bryan
Copy link
Owner

I'm going to close this for now seeing as it would prevent future optimisations like compression.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants