pub enum Literal {
Int(i64),
Float(f64),
Text(String),
Duration(i64),
Date(i32),
Moment(i64),
}Expand description
Primitive literal values.
These are opaque values that compute via hardware ALU, not recursion.
Variants§
Int(i64)
64-bit signed integer
Float(f64)
64-bit floating point
Text(String)
UTF-8 string
Duration(i64)
Duration in nanoseconds (signed for negative offsets like “5 min early”)
Date(i32)
Calendar date as days since Unix epoch (i32 gives ±5.8 million year range)
Moment(i64)
Instant in time as nanoseconds since Unix epoch (UTC)
Trait Implementations§
impl Eq for Literal
impl StructuralPartialEq for Literal
Auto Trait Implementations§
impl Freeze for Literal
impl RefUnwindSafe for Literal
impl Send for Literal
impl Sync for Literal
impl Unpin for Literal
impl UnwindSafe for Literal
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