-
Notifications
You must be signed in to change notification settings - Fork 21
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 quick_error to all of our error ADTS #17
Conversation
coltfred
commented
Oct 18, 2018
- Added quick_error to error adts. This results in us having the Error trait implemented without writing them ourselves. See the documentation for details.
- All public errors now have informative messages, but also contain links to the sub errors that caused them.
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.
Nice improvement!
src/internal/mod.rs
Outdated
@@ -819,7 +809,7 @@ impl<FP: Field + NonAdjacentForm> ReencryptionKey<FP> { | |||
/// | |||
/// # Return | |||
/// ReencryptedValue - if the value could be successfully reencrypted | |||
/// - Left(SignatureFailed|ReencryptionKeyIsCorrupt) - if the signatures weren't valid. | |||
/// - Left(InvalidEncryptedMessageSignature|ReencryptionKeyIsCorrupt) - if the signatures weren't valid. |
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.
I guess Left
isn't technically true here...
Do we have a standard way of documenting errors?
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.
We should say Err instead. I'll fix that.