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

Some iterations over Map#keySet calls Map#get(key) during iteration #1727

Closed
lyxell opened this issue Aug 18, 2021 · 1 comment
Closed

Some iterations over Map#keySet calls Map#get(key) during iteration #1727

lyxell opened this issue Aug 18, 2021 · 1 comment
Assignees

Comments

@lyxell
Copy link
Contributor

lyxell commented Aug 18, 2021

As part of a research project I've been running Logifix on open source repositories. When running Logifix on karate I found that there exists iterations over Map#keySet where Map#get is called in the loop, using the key. This can be made more efficient using Map#entrySet instead.

I will submit a patch generated by Logifix in an upcoming PR.

@ptrthomas
Copy link
Member

thanks 👍 closing with codequality tag

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