1
0
This commit is contained in:
Jeff 2024-07-11 08:10:12 -04:00
parent 48f3ccdd58
commit 1794f7559c
3 changed files with 5 additions and 3 deletions

View File

@ -214,8 +214,8 @@ impl AbstractNode for Logic {
left_boolean || right_boolean left_boolean || right_boolean
} }
Logic::Not(statement) => { Logic::Not(expression) => {
let boolean = run_and_expect_boolean(statement)?; let boolean = run_and_expect_boolean(expression)?;
!boolean !boolean
} }

View File

@ -820,6 +820,8 @@ impl Function {
debug!("Calling function"); debug!("Calling function");
self.body
.define_and_validate(&self.context, false, SourcePosition(0, usize::MAX))?;
self.body self.body
.evaluate(&self.context, false, SourcePosition(0, usize::MAX)) .evaluate(&self.context, false, SourcePosition(0, usize::MAX))
} }

View File

@ -105,7 +105,7 @@ fn recursion() {
} }
} }
fib(4) fib(8)
" "
), ),
Ok(Some(Value::integer(13))) Ok(Some(Value::integer(13)))