We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Describe the bug I accidently subtracted 10^9 from 0u64 and it did not throw an error but returned 2^64 - 10^9.
10^9
0u64
2^64 - 10^9
Suggest Is there a way implementing SafeMath operation to check math overflows?
The text was updated successfully, but these errors were encountered:
I think what you need is: https://github.com/massalabs/as/blob/193a8f5d77d0a9c99c1aad9141c62a5489cd0e9c/packages/as-types/assembly/safeMath.ts#L13
Sorry, something went wrong.
No branches or pull requests
Describe the bug
I accidently subtracted
10^9
from0u64
and it did not throw an error but returned2^64 - 10^9
.Suggest
Is there a way implementing SafeMath operation to check math overflows?
The text was updated successfully, but these errors were encountered: