pub enum UnversionizeError {
Upgrade {
from_vers: String,
into_vers: String,
source: Box<dyn Error + Send + Sync>,
},
Conversion {
from_type: String,
source: Box<dyn Error + Send + Sync>,
},
ArrayLength {
expected_size: usize,
found_size: usize,
},
DeprecatedVersion(DeprecatedVersionError),
SkippedVariant {
variant_name: String,
},
}
Expand description
Errors that can arise in the unversionizing process.
Variants§
Upgrade
An error in the upgrade between vers_from
and vers_into
Conversion
An error has been returned in the conversion method provided by the try_from
parameter
attribute
ArrayLength
The length of a statically sized array is wrong
DeprecatedVersion(DeprecatedVersionError)
A deprecated version has been found
SkippedVariant
User tried to unversionize an enum variant with the #[versionize(skip)]
attribute
Implementations§
Trait Implementations§
Source§impl Debug for UnversionizeError
impl Debug for UnversionizeError
Source§impl Display for UnversionizeError
impl Display for UnversionizeError
Source§impl Error for UnversionizeError
impl Error for UnversionizeError
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 From<Infallible> for UnversionizeError
impl From<Infallible> for UnversionizeError
Source§fn from(_value: Infallible) -> Self
fn from(_value: Infallible) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for UnversionizeError
impl !RefUnwindSafe for UnversionizeError
impl Send for UnversionizeError
impl Sync for UnversionizeError
impl Unpin for UnversionizeError
impl !UnwindSafe for UnversionizeError
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