#[non_exhaustive]pub enum Mismatch {
Primitive {
expected: &'static str,
actual: &'static str,
},
EnumMember {
member: String,
declared: Vec<String>,
},
SelectMember {
written: String,
select: String,
},
FixedWidth {
expected: usize,
actual: usize,
},
ExpectedReference {
declared: String,
actual: &'static str,
},
}Expand description
Why a value does not fit its declared type.
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.
Primitive
The written form is not what the primitive accepts.
Fields
EnumMember
An enumeration constant the schema does not declare.
Fields
SelectMember
A typed value whose type is not a member of the declared SELECT.
FixedWidth
A STRING(n) FIXED value written at the wrong width.
ExpectedReference
A value that is not an entity reference, in a slot only an entity reference can fill: an entity-typed slot, or a SELECT of entities.
Trait Implementations§
impl Eq for Mismatch
impl StructuralPartialEq for Mismatch
Auto Trait Implementations§
impl Freeze for Mismatch
impl RefUnwindSafe for Mismatch
impl Send for Mismatch
impl Sync for Mismatch
impl Unpin for Mismatch
impl UnsafeUnpin for Mismatch
impl UnwindSafe for Mismatch
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