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

Implement accessors for inner reader on StreamDecoder #62

Merged
merged 3 commits into from
May 29, 2024

Conversation

ifd3f
Copy link
Contributor

@ifd3f ifd3f commented May 19, 2024

I have an application where I access the inner Read object to get some statistics on how far we've read. This adds get_ref and get_mut, and another one where you can destructure to get both the Read and FrameDecoder.

Copy link
Owner

@KillingSpark KillingSpark left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This seems like a good addition to the api of the streaming decoder. I have some thoughts about the naming, but otherwise this looks good 👍

src/streaming_decoder.rs Outdated Show resolved Hide resolved
src/streaming_decoder.rs Outdated Show resolved Hide resolved
src/streaming_decoder.rs Show resolved Hide resolved
src/streaming_decoder.rs Show resolved Hide resolved
@ifd3f
Copy link
Contributor Author

ifd3f commented May 23, 2024

Seems I forgot to run with --no-default-features, oops.

@KillingSpark
Copy link
Owner

Seems I forgot to run with --no-default-features, oops.

No worries, I do that all the time. But that's what the CI is here for :)

@KillingSpark
Copy link
Owner

Don't worry about the clippy thing, I can fix that after merging. I'll do that later today 👍

Thanks for the contribution!

@KillingSpark KillingSpark merged commit 16fee8c into KillingSpark:master May 29, 2024
1 of 2 checks passed
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