pub enum Value {
Null,
String(String),
Number(f64),
Boolean(bool),
Array(Vec<Value>),
Object(HashMap<String, Value>),
}Expand description
A runtime value in the Patchwork language.
Variants§
Null
The null value.
String(String)
A string value.
Number(f64)
A numeric value (always f64, like JavaScript).
Boolean(bool)
A boolean value.
Array(Vec<Value>)
An array of values.
Object(HashMap<String, Value>)
An object with string keys.
Implementations§
Trait Implementations§
impl StructuralPartialEq for Value
Auto Trait Implementations§
impl Freeze for Value
impl RefUnwindSafe for Value
impl Send for Value
impl Sync for Value
impl Unpin for Value
impl UnsafeUnpin for Value
impl UnwindSafe for Value
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