-
Notifications
You must be signed in to change notification settings - Fork 201
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
Primitive type equivalent of Map#forEach is missing #279
Comments
Map#fastForEach |
Sorry for bugging you again, but there is just a FastEntrySet#fastForEach(Consumer). I opened this issue because I am missing the "syntactic sugar variant" using a BiConsumer. That allows for way better readable code like So it would be nice if you would reopen this issue. |
I now see your point. The problem is that we do not have type-specific BiConsumers. Are there some provided by the JDK? |
if I recall correctly, there are none indeed! It would certainly be nice to have it, not only from code style but also performance ( |
It looks like this also came up when Java 8 support was discussed: #64 (comment) |
I would like to iterate a map's entry set without the need for boxing. I found no equivalent for Map#forEach though.
One could achieve this via iterating over
*2*EntrySet()
but the code looks less readable then.The text was updated successfully, but these errors were encountered: