mirror of
https://github.com/nushell/nushell.git
synced 2025-08-13 03:47:44 +02:00
Add booleans and fix semicolon shortcircuit (#1620)
This commit is contained in:
@ -152,6 +152,14 @@ fn evaluate_reference(name: &hir::Variable, scope: &Scope, tag: Tag) -> Result<V
|
||||
hir::Variable::It(_) => Ok(scope.it.value.clone().into_value(tag)),
|
||||
hir::Variable::Other(name, _) => match name {
|
||||
x if x == "$nu" => crate::evaluate::variables::nu(tag),
|
||||
x if x == "$true" => Ok(Value {
|
||||
value: UntaggedValue::boolean(true),
|
||||
tag,
|
||||
}),
|
||||
x if x == "$false" => Ok(Value {
|
||||
value: UntaggedValue::boolean(false),
|
||||
tag,
|
||||
}),
|
||||
x => Ok(scope
|
||||
.vars
|
||||
.get(x)
|
||||
|
Reference in New Issue
Block a user