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

derive Clone on BitQueue, BitReader #8

Merged
merged 1 commit into from
Jun 14, 2021
Merged

Conversation

scottlamb
Copy link
Contributor

This is useful for querying the position within a H.264 bitstream
relative to the final one bit; details in dholroyd/h264-reader#28.

The default #![derive(Clone)] behavior is nice: BitReader will be
Clone iff the backing std::io::Read is also Clone. Out of paranoia,
I added a test that clone works properly and that it's still possible
to instantiate a BitReader with a non-Clone R.

This is useful for querying the position within a H.264 bitstream
relative to the final one bit; details in dholroyd/h264-reader#28.

The default #![derive(Clone)] behavior is nice: BitReader will be
Clone iff the backing std::io::Read is also Clone. Out of paranoia,
I added a test that clone works properly and that it's still possible
to instantiate a BitReader with a non-Clone R.
@tuffy tuffy merged commit 0bb782a into tuffy:master Jun 14, 2021
@scottlamb
Copy link
Contributor Author

Thanks for the quick merge and release!

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