pub enum SecretAllocationError {
TooLong {
maximum: usize,
actual: usize,
},
CapacityOverflow,
Allocation(TryReserveError),
}Expand description
Error returned when fallible dynamic secret allocation fails.
Public lengths and configured maxima are not treated as secret data.
Variants§
TooLong
The requested public length exceeded the caller’s maximum.
CapacityOverflow
Arithmetic for the required allocation capacity overflowed.
Allocation(TryReserveError)
The allocator could not reserve the requested storage.
Trait Implementations§
Source§impl Debug for SecretAllocationError
impl Debug for SecretAllocationError
Source§impl Display for SecretAllocationError
Available on crate feature alloc only.
impl Display for SecretAllocationError
Available on crate feature
alloc only.Source§impl Error for SecretAllocationError
Available on crate feature std only.
impl Error for SecretAllocationError
Available on crate feature
std only.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<E> From<SecretAllocationError> for SecretGenerateError<E>
Available on crate feature alloc only.
impl<E> From<SecretAllocationError> for SecretGenerateError<E>
Available on crate feature
alloc only.Source§fn from(error: SecretAllocationError) -> Self
fn from(error: SecretAllocationError) -> Self
Converts to this type from the input type.
Source§impl From<TryReserveError> for SecretAllocationError
Available on crate feature alloc only.
impl From<TryReserveError> for SecretAllocationError
Available on crate feature
alloc only.Source§fn from(error: TryReserveError) -> Self
fn from(error: TryReserveError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for SecretAllocationError
impl RefUnwindSafe for SecretAllocationError
impl Send for SecretAllocationError
impl Sync for SecretAllocationError
impl Unpin for SecretAllocationError
impl UnsafeUnpin for SecretAllocationError
impl UnwindSafe for SecretAllocationError
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