Skip to content

Commit

Permalink
DecodeError should implement std::error::Error
Browse files Browse the repository at this point in the history
  • Loading branch information
conduition committed Nov 30, 2024
1 parent bb502ec commit 126eb44
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/errors.rs
Original file line number Diff line number Diff line change
Expand Up @@ -355,6 +355,8 @@ impl<T> fmt::Display for DecodeError<T> {
}
}

impl<T: fmt::Debug> std::error::Error for DecodeError<T> {}

impl<T> From<secp::errors::InvalidPointBytes> for DecodeError<T> {
fn from(_: secp::errors::InvalidPointBytes) -> Self {
DecodeError::new(DecodeFailureReason::InvalidPoint)
Expand Down

0 comments on commit 126eb44

Please sign in to comment.