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

Using require instead of assert in library functions #48

Merged
merged 1 commit into from
Sep 7, 2018

Conversation

aalavandhan
Copy link
Member

@brandoniles
Copy link
Member

I think either works, depending on whether you see it being an error in user input or a system accuracy error. I lean toward the second, which would use assert.

Zeppelin's newer version also uses assert instead of require:
https://github.com/OpenZeppelin/openzeppelin-zos/blob/master/contracts/math/SafeMath.sol

@aalavandhan
Copy link
Member Author

aalavandhan commented Sep 7, 2018

@brandoniles
Copy link
Member

@aalavandhan aalavandhan merged commit 4ce1032 into master Sep 7, 2018
@aalavandhan aalavandhan deleted the assert-to-require branch September 7, 2018 20:56
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.

2 participants