Skip to content

Commit 6a64628

Browse files
committed
Selective fix for js_pass_flatten_and_mark_dead
1 parent fc38b25 commit 6a64628

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

compiler/core/js_pass_flatten_and_mark_dead.ml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -245,6 +245,9 @@ let subst_map (substitution : J.expression Hash_ident.t) =
245245
turn a runtime crash into compile time crash : )
246246
*)
247247
match Ext_list.nth_opt ls (Int32.to_int i) with
248+
| Some {expression_desc = J.Var (Id {name = "make"})}
249+
when !Js_config.jsx_preserve ->
250+
super.expression self x
248251
| Some
249252
({expression_desc = J.Var _ | Number _ | Str _ | Undefined _} as
250253
x) ->

0 commit comments

Comments
 (0)