@@ -138,14 +138,14 @@ module Operators = struct
138
138
let lte = compare " <=" ( < = )
139
139
let and_ = condition " and" ( && )
140
140
let or_ = condition " or" ( || )
141
- let eq l r = Output. return (`Bool (l = r))
142
- let notEq l r = Output. return (`Bool (l <> r))
141
+ let equal l r = Output. return (`Bool (l = r))
142
+ let not_equal l r = Output. return (`Bool (l <> r))
143
143
144
144
(* Since + is used to concat strings, objects, lists, we don't use apply_op *)
145
145
let add = add " +"
146
- let sub = apply_op " -" (fun l r -> l -. r)
147
- let mult = apply_op " *" (fun l r -> l *. r)
148
- let div = apply_op " /" (fun l r -> l /. r)
146
+ let subtract = apply_op " -" (fun l r -> l -. r)
147
+ let multiply = apply_op " *" (fun l r -> l *. r)
148
+ let divide = apply_op " /" (fun l r -> l /. r)
149
149
end
150
150
151
151
let keys (json : Json.t ) =
@@ -341,15 +341,15 @@ let rec compile expression json : (Json.t list, string) result =
341
341
| Operation (left , op , right ) -> (
342
342
match op with
343
343
| Add -> operation left right Operators. add json
344
- | Sub -> operation left right Operators. sub json
345
- | Mult -> operation left right Operators. mult json
346
- | Div -> operation left right Operators. div json
347
- | Gt -> operation left right Operators. gt json
348
- | Ge -> operation left right Operators. gte json
349
- | St -> operation left right Operators. lt json
350
- | Se -> operation left right Operators. lte json
351
- | Eq -> operation left right Operators. eq json
352
- | Neq -> operation left right Operators. notEq json
344
+ | Subtract -> operation left right Operators. subtract json
345
+ | Multiply -> operation left right Operators. multiply json
346
+ | Divide -> operation left right Operators. divide json
347
+ | Greater_than -> operation left right Operators. gt json
348
+ | Greater_than_or_equal -> operation left right Operators. gte json
349
+ | Less_than -> operation left right Operators. lt json
350
+ | Less_than_or_equal -> operation left right Operators. lte json
351
+ | Equal -> operation left right Operators. equal json
352
+ | Not_equal -> operation left right Operators. not_equal json
353
353
| And -> operation left right Operators. and_ json
354
354
| Or -> operation left right Operators. or_ json)
355
355
| Literal literal -> (
0 commit comments