Fixed bug with max() function, tested math syscalls

This commit is contained in:
2025-12-06 22:46:51 -07:00
parent 19d6679229
commit f53f2f878a
3 changed files with 388 additions and 13 deletions

View File

@@ -1889,7 +1889,7 @@ impl<'a> Parser<'a> {
Ok(SysCall::Math(Math::Log(boxed!(arg))))
}
"max" => {
check_length(self, &invocation.arguments, 1)?;
check_length(self, &invocation.arguments, 2)?;
let mut args = invocation.arguments.into_iter();
let arg1 = args.next().ok_or(Error::UnexpectedEOF)?;
let arg2 = args.next().ok_or(Error::UnexpectedEOF)?;