aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xevaluator.ml3
1 files changed, 2 insertions, 1 deletions
diff --git a/evaluator.ml b/evaluator.ml
index 075f728..64d260e 100755
--- a/evaluator.ml
+++ b/evaluator.ml
@@ -285,7 +285,6 @@ let () = begin
CompareNum.register t_int;
register0 "rand" f_number D.Num.rnd;
- register1 "exp" t_int f_number (fun x -> D.Num.of_float (exp @@ D.Num.to_float x));
register0 "pi" f_number (fun () -> D.Num.of_float (4. *. atan 1.));
register1 "sin" t_int f_number (fun x -> D.Num.of_float (sin @@ D.Num.to_float x));
register1 "cos" t_int f_number (fun x -> D.Num.of_float (cos @@ D.Num.to_float x));
@@ -301,6 +300,8 @@ let () = begin
);
register1 "sqrt" t_int f_number (fun x -> D.Num.of_float (sqrt @@ D.Num.to_float x));
+ register1 "exp" t_int f_number (fun x -> D.Num.of_float (exp @@ D.Num.to_float x));
+ register1 "ln" t_int f_number (fun x -> D.Num.of_float (log @@ D.Num.to_float x));
register3 "if" (t_bool, t_int, t_int) f_number if_;
register3 "if" (t_bool, t_bool, t_bool) f_bool if_;