Skip to content

Commit b0432b7

Browse files
committed
number
1 parent 32ccf6b commit b0432b7

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

compiler/core/js_exp_make.ml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -794,7 +794,7 @@ let rec simplify_and (e1 : t) (e2 : t) : t option =
794794
| ( Bin
795795
( EqEqEq,
796796
{expression_desc = Typeof {expression_desc = Var ia}},
797-
{expression_desc = Str {txt = "boolean" | "string"}} ),
797+
{expression_desc = Str {txt = "boolean" | "string" | "number"}} ),
798798
Bin
799799
( EqEqEq,
800800
{expression_desc = Var ib},
@@ -806,7 +806,7 @@ let rec simplify_and (e1 : t) (e2 : t) : t option =
806806
Bin
807807
( EqEqEq,
808808
{expression_desc = Typeof {expression_desc = Var ia}},
809-
{expression_desc = Str {txt = "boolean" | "string"}} ) )
809+
{expression_desc = Str {txt = "boolean" | "string" | "number"}} ) )
810810
when Js_op_util.same_vident ia ib ->
811811
(* Note: case boolean / Bool _ is handled above *)
812812
Some false_

0 commit comments

Comments
 (0)