-
Notifications
You must be signed in to change notification settings - Fork 399
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
Support errors.Is
and errors.As
in the standard gno errors
package
#486
Labels
help wanted
Want to contribute? We recommend these issues.
Milestone
Comments
Related to #239 |
Btw, you don't need to wait for #239 to be done to just port those missing helpers. |
Closed as part of some @moul PR 🙏 |
Nope, doesn't exist yet: https://github.com/gnolang/gno/blob/master/gnovm/stdlibs/errors/errors.gno |
Ah, it was part of the uassert / urequire packages 👍 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Description
Currently, the only way to compare errors in
.gno
packages is to use the equals operator==
, as users are limited to the standarderrors
package.Gno should support other useful methods from the Go standard
errors
library, likeerrors.Is
anderrors.As
, because it makes it easy to do error comparisons and brings it closer to idiomatic Go.The text was updated successfully, but these errors were encountered: