#[non_exhaustive]pub enum TokenEncodeError {
CoefficientOutOfRange {
index: usize,
value: i16,
},
}Expand description
Errors surfaced by the §13 token-block encoder.
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.
CoefficientOutOfRange
A coefficient magnitude exceeded the §13.2 alphabet’s largest
representable value (67 + (2^11 - 1) = 2114). The encoder
makes no attempt to clamp; the caller is expected to have run
the §14 quantizer and have its results in range. Surfaces the
offending raster index and value so the caller can pin the
quantizer bug.
Trait Implementations§
Source§impl Clone for TokenEncodeError
impl Clone for TokenEncodeError
impl Copy for TokenEncodeError
Source§impl Debug for TokenEncodeError
impl Debug for TokenEncodeError
Source§impl Display for TokenEncodeError
impl Display for TokenEncodeError
impl Eq for TokenEncodeError
Source§impl Error for TokenEncodeError
impl Error for TokenEncodeError
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 TokenEncodeError
impl PartialEq for TokenEncodeError
impl StructuralPartialEq for TokenEncodeError
Auto Trait Implementations§
impl Forget for TokenEncodeError
impl Freeze for TokenEncodeError
impl Move for TokenEncodeError
impl RefUnwindSafe for TokenEncodeError
impl Send for TokenEncodeError
impl Sync for TokenEncodeError
impl Unpin for TokenEncodeError
impl UnsafeUnpin for TokenEncodeError
impl UnwindSafe for TokenEncodeError
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