blob: dcd238a7cd39d6a507b1208fa083ac1c91903012 (
plain) (
tree)
|
|
#[derive(Clone, Debug, PartialEq)]
pub enum Value {
Nil,
Bool(bool),
Number(f64),
}
impl Value {
pub fn is_falsey(&self) -> bool {
match self {
Value::Nil => true,
Value::Bool(false) => true,
_ => false,
}
}
}
|