File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -1045,13 +1045,15 @@ module Constant = struct
1045
1045
if b then return c else store_in_global c
1046
1046
| Const_named name -> store_in_global ~name c
1047
1047
| Mutated ->
1048
+ let * typ = Type. string_type in
1048
1049
let name = Code.Var. fresh_n " const" in
1050
+ let * placeholder = array_placeholder typ in
1049
1051
let * () =
1050
1052
register_global
1051
1053
~constant: true
1052
1054
name
1053
- { mut = true ; typ = Type. value }
1054
- ( W. RefI31 ( Const ( I32 0l )))
1055
+ { mut = true ; typ = Ref { nullable = false ; typ = Type typ } }
1056
+ placeholder
1055
1057
in
1056
1058
let * () = register_init_code (instr (W. GlobalSet (name, c))) in
1057
1059
return (W. GlobalGet name)
@@ -1111,6 +1113,7 @@ module Closure = struct
1111
1113
id
1112
1114
in
1113
1115
info.id < - Some env_type_id;
1116
+ (*
1114
1117
Format.eprintf
1115
1118
"%a@."
1116
1119
(Format.pp_print_list
@@ -1132,6 +1135,7 @@ module Closure = struct
1132
1135
"%s"
1133
1136
(Option.value ~default:"???" (Code.Var.get_name v))))))
1134
1137
env_type;
1138
+ *)
1135
1139
match info.Closure_conversion. functions with
1136
1140
| [] -> assert false
1137
1141
| [ _ ] ->
You can’t perform that action at this time.
0 commit comments