#[repr(u8)]pub enum ValueTag {
Null = 0,
False = 1,
True = 3,
Int = 4,
Float = 5,
Text = 6,
Container = 7,
}Expand description
What the low three bits of a value header say the value is.
The numbers are the format, so they are written out rather than derived from declaration order, and 2 is missing on purpose: false and true are 1 and 3 so that the low bit of a boolean is the boolean.
Variants§
Null = 0
null.
False = 1
false.
True = 3
true.
Int = 4
A signed integer, stored in one, two, four or eight bytes.
Float = 5
A 64 bit float.
Text = 6
A UTF-8 string.
Container = 7
An object or an array, told apart by doc_flags::ARRAY.
Implementations§
Trait Implementations§
impl Copy for ValueTag
impl Eq for ValueTag
impl StructuralPartialEq for ValueTag
Auto Trait Implementations§
impl Freeze for ValueTag
impl RefUnwindSafe for ValueTag
impl Send for ValueTag
impl Sync for ValueTag
impl Unpin for ValueTag
impl UnsafeUnpin for ValueTag
impl UnwindSafe for ValueTag
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