Created
June 23, 2021 16:52
-
-
Save DrPeterVanNostrand/9dc81ceabb3b86644d904578ede9291b to your computer and use it in GitHub Desktop.
asdf
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/// An error that may occur when trying to decode an `EncodedPoint`. | |
#[derive(thiserror::Error, Debug)] | |
pub enum GroupDecodingError { | |
/// The coordinate(s) do not lie on the curve. | |
#[error("coordinate(s) do not lie on the curve")] | |
NotOnCurve, | |
/// The element is not part of the r-order subgroup. | |
#[error("the element is not part of an r-order subgroup")] | |
NotInSubgroup, | |
/// One of the coordinates could not be decoded | |
#[error("coordinate(s) could not be decoded")] | |
CoordinateDecodingError(&'static str, #[source] PrimeFieldDecodingError), | |
/// The compression mode of the encoded element was not as expected | |
#[error("encoding has unexpected compression mode")] | |
UnexpectedCompressionMode, | |
/// The encoding contained bits that should not have been set | |
#[error("encoding has unexpected information")] | |
UnexpectedInformation, | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment