#[non_exhaustive]pub enum Pep440Error {
TooLong,
Invalid,
NumberTooLarge,
}Expand description
Why a string is not a PEP 440 version.
Experimental: may change in a 0.x minor release.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
TooLong
Longer than MAX_PEP440_BYTES.
Invalid
Not a version in the form the specification accepts.
NumberTooLarge
A number does not fit in 64 bits.
Trait Implementations§
Source§impl Clone for Pep440Error
impl Clone for Pep440Error
Source§impl Debug for Pep440Error
impl Debug for Pep440Error
Source§impl Display for Pep440Error
impl Display for Pep440Error
impl Eq for Pep440Error
Source§impl Error for Pep440Error
impl Error for Pep440Error
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Source§impl PartialEq for Pep440Error
impl PartialEq for Pep440Error
impl StructuralPartialEq for Pep440Error
Auto Trait Implementations§
impl Forget for Pep440Error
impl Freeze for Pep440Error
impl Move for Pep440Error
impl RefUnwindSafe for Pep440Error
impl Send for Pep440Error
impl Sync for Pep440Error
impl Unpin for Pep440Error
impl UnsafeUnpin for Pep440Error
impl UnwindSafe for Pep440Error
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more