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

More derives for key::Error #551

Merged
merged 1 commit into from Feb 21, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/util/key.rs
Expand Up @@ -27,7 +27,7 @@ use hash_types::{PubkeyHash, WPubkeyHash};
use util::base58;

/// A key-related error.
#[derive(Debug)]
#[derive(Debug, PartialEq, Eq, Clone)]
pub enum Error {
/// Base58 encoding error
Base58(base58::Error),
Expand All @@ -39,8 +39,8 @@ pub enum Error {
impl fmt::Display for Error {
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match *self {
Error::Base58(ref e) => write!(f, "base58 error: {}", e),
Error::Secp256k1(ref e) => write!(f, "secp256k1 error: {}", e),
Error::Base58(ref e) => write!(f, "Key base58 error: {}", e),
Error::Secp256k1(ref e) => write!(f, "Key secp256k1 error: {}", e),
}
}
}
Expand Down