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

Add BytesSet #2395

Merged
merged 6 commits into from Nov 4, 2020
Merged

Add BytesSet #2395

merged 6 commits into from Nov 4, 2020

Conversation

nventuro
Copy link
Contributor

This adds a (trivial) set for type bytes32. bytes32 is very commonly used for identifiers, since it is the result of a hash operation, and unlike uint256 doesn't have arithmetic operators.

Copy link
Contributor

@frangio frangio left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

I think we should change the name to Bytes32Set, since bytes is the type for dynamic length byte arrays in Solidity. (Note that UintSet doesn't have this problem because uint and uint256 are synonyms.)

@nventuro nventuro requested a review from frangio November 4, 2020 18:28
Copy link
Contributor

@frangio frangio left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Thanks!

@frangio frangio merged commit fcdf8f4 into OpenZeppelin:master Nov 4, 2020
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

Successfully merging this pull request may close these issues.

None yet

2 participants