-
Notifications
You must be signed in to change notification settings - Fork 9.6k
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
Update hashcode to always generate a positive index #967
Conversation
import ( | ||
"hash/crc32" | ||
) | ||
import "hash/crc32" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Stylewise I usually just prefer to use the parens, because it makes it easy to add imports later, despite being not the most optimal way (visually) to put it.
Style nitpicks but looks great. Can you also mention the issue # this fixes? (the route53 thing) |
@mitchellh updated to fix nitpicks. There was no original issue for this; I was trying to work on something mostly unrelated and ran into it |
@clint I thought this fixed the route53 issue though? Oh, that was a new one you found? |
This LGTM. Merge! 🚢 |
@mitchellh I was trying to work on something and add a new acceptance test, but the existing one(s) didn't pass. With this, the acceptance tests pass now. |
It actually fix the issue #873 😸 |
@ggiamarchi well then, hooray I'm helping! 😄 |
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further. |
When generating an int index for Set, we need to ensure that
hash.String
returns a positive integer.