Skip to content

Commit 77a4630

Browse files
committed
use bigint_comp
1 parent d01c73d commit 77a4630

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

jscomp/core/lam_compile_primitive.ml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -411,14 +411,14 @@ let translate output_prefix loc (cxt : Lam_compile_context.t)
411411
match args with
412412
| [ { expression_desc = Number (BigInt _) } as a; { expression_desc = Number (BigInt _) } as b ]
413413
when Js_analyzer.is_okay_to_duplicate a && Js_analyzer.is_okay_to_duplicate b ->
414-
E.econd (E.js_comp Clt a b) a b
414+
E.econd (E.bigint_comp Clt a b) a b
415415
| [ a; b ] -> E.runtime_call Primitive_modules.bigint "min" args
416416
| _ -> assert false)
417417
| Pbigintmax -> (
418418
match args with
419419
| [ { expression_desc = Number (BigInt _) } as a; { expression_desc = Number (BigInt _) } as b ]
420420
when Js_analyzer.is_okay_to_duplicate a && Js_analyzer.is_okay_to_duplicate b ->
421-
E.econd (E.js_comp Cgt a b) a b
421+
E.econd (E.bigint_comp Cgt a b) a b
422422
| [ a; b ] -> E.runtime_call Primitive_modules.bigint "max" args
423423
| _ -> assert false)
424424
| Pstringorder -> (

0 commit comments

Comments
 (0)