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

Bytes Iterator for Buffer #32

Open
mmstick opened this issue Mar 6, 2017 · 2 comments
Open

Bytes Iterator for Buffer #32

mmstick opened this issue Mar 6, 2017 · 2 comments

Comments

@mmstick
Copy link
Contributor

mmstick commented Mar 6, 2017

If you wouldn't mind, I'd like to see a bytes() iterator for the Buffer structure. Perhaps even a to_string() and as_bytes() method too. Basically, when writing data to an output, it needs to be in a raw &[u8] format.

@MovingtoMars
Copy link
Owner

I'll probably implement this tomorrow if no-one else gets there first.

@MovingtoMars
Copy link
Owner

57ea1d0 should do most of what you're looking for.

(Buffer already has to_string() as it implements std::fmt::Display)

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

No branches or pull requests

2 participants