lua: math.sinh/cosh/tanh hyperbolic functions
Some checks failed
Test, Build, and Deploy / test-build-deploy (push) Has been cancelled

This commit is contained in:
2026-04-25 01:02:34 +00:00
parent 73694a3a84
commit 702e7c8eac
4 changed files with 46 additions and 39 deletions

View File

@@ -1336,6 +1336,9 @@
(define lua-math-atan (fn (x) (atan (lua-math-num "atan" x))))
(define lua-math-atan2 (fn (y x) (atan2 (lua-math-num "atan2" y) (lua-math-num "atan2" x))))
(define lua-math-pow (fn (a b) (pow (lua-math-num "pow" a) (lua-math-num "pow" b))))
(define lua-math-sinh (fn (x) (sinh (lua-math-num "sinh" x))))
(define lua-math-cosh (fn (x) (cosh (lua-math-num "cosh" x))))
(define lua-math-tanh (fn (x) (tanh (lua-math-num "tanh" x))))
(define lua-math-log
(fn (&rest args)
@@ -1421,6 +1424,9 @@
(dict-set! math "acos" lua-math-acos)
(dict-set! math "atan" lua-math-atan)
(dict-set! math "atan2" lua-math-atan2)
(dict-set! math "sinh" lua-math-sinh)
(dict-set! math "cosh" lua-math-cosh)
(dict-set! math "tanh" lua-math-tanh)
(dict-set! math "deg" lua-math-deg)
(dict-set! math "rad" lua-math-rad)
(dict-set! math "min" lua-math-min)