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 bit iterator #36

Open
Veykril opened this issue Oct 26, 2019 · 1 comment
Open

Implement bit iterator #36

Veykril opened this issue Oct 26, 2019 · 1 comment

Comments

@Veykril
Copy link

Veykril commented Oct 26, 2019

I think a bit iterator that returns true and false for each bit correspondingly would be a nice addition to this library. I was in need of one which is why I already personally implemented it, though I am not sure about its performance.

The use case I have for it for example, is that one could zip this iterator with an iterator over a Vec and filter out all elements where the corresponding bit is unset for example.

@bluss
Copy link
Member

bluss commented Oct 26, 2019

Sounds cool, but I think we will struggle to deliver good performance through Iterator::next (maybe fold will be fine). The filtering operation could maybe even have a more specialized api.

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

No branches or pull requests

2 participants