@@ -102,7 +102,14 @@ module Make (Target : Target_sig.S) = struct
102102 let param_names = args @ [ f ] in
103103 let locals, body = function_body ~context ~param_names ~body in
104104 W. Function
105- { name; exported_name = None ; typ = func_type 1 ; param_names; locals; body }
105+ { name
106+ ; exported_name = None
107+ ; typ = None
108+ ; signature = func_type 1
109+ ; param_names
110+ ; locals
111+ ; body
112+ }
106113
107114 let curry_name n m = Printf. sprintf " curry_%d_%d" n m
108115
@@ -130,7 +137,14 @@ module Make (Target : Target_sig.S) = struct
130137 let param_names = [ x; f ] in
131138 let locals, body = function_body ~context ~param_names ~body in
132139 W. Function
133- { name; exported_name = None ; typ = func_type 1 ; param_names; locals; body }
140+ { name
141+ ; exported_name = None
142+ ; typ = None
143+ ; signature = func_type 1
144+ ; param_names
145+ ; locals
146+ ; body
147+ }
134148 :: functions
135149
136150 let curry ~arity ~name = curry ~arity arity ~name
@@ -174,7 +188,14 @@ module Make (Target : Target_sig.S) = struct
174188 let param_names = args @ [ f ] in
175189 let locals, body = function_body ~context ~param_names ~body in
176190 W. Function
177- { name; exported_name = None ; typ = func_type 2 ; param_names; locals; body }
191+ { name
192+ ; exported_name = None
193+ ; typ = None
194+ ; signature = func_type 2
195+ ; param_names
196+ ; locals
197+ ; body
198+ }
178199
179200 let cps_curry_name n m = Printf. sprintf " cps_curry_%d_%d" n m
180201
@@ -206,7 +227,14 @@ module Make (Target : Target_sig.S) = struct
206227 let param_names = [ x; cont; f ] in
207228 let locals, body = function_body ~context ~param_names ~body in
208229 W. Function
209- { name; exported_name = None ; typ = func_type 2 ; param_names; locals; body }
230+ { name
231+ ; exported_name = None
232+ ; typ = None
233+ ; signature = func_type 2
234+ ; param_names
235+ ; locals
236+ ; body
237+ }
210238 :: functions
211239
212240 let cps_curry ~arity ~name = cps_curry ~arity arity ~name
@@ -243,7 +271,14 @@ module Make (Target : Target_sig.S) = struct
243271 let param_names = l @ [ f ] in
244272 let locals, body = function_body ~context ~param_names ~body in
245273 W. Function
246- { name; exported_name = None ; typ = func_type arity; param_names; locals; body }
274+ { name
275+ ; exported_name = None
276+ ; typ = None
277+ ; signature = func_type arity
278+ ; param_names
279+ ; locals
280+ ; body
281+ }
247282
248283 let cps_apply ~context ~arity ~name =
249284 assert (arity > 2 );
@@ -283,7 +318,14 @@ module Make (Target : Target_sig.S) = struct
283318 let param_names = l @ [ f ] in
284319 let locals, body = function_body ~context ~param_names ~body in
285320 W. Function
286- { name; exported_name = None ; typ = func_type arity; param_names; locals; body }
321+ { name
322+ ; exported_name = None
323+ ; typ = None
324+ ; signature = func_type arity
325+ ; param_names
326+ ; locals
327+ ; body
328+ }
287329
288330 let dummy ~context ~cps ~arity ~name =
289331 let arity = if cps then arity + 1 else arity in
@@ -311,7 +353,14 @@ module Make (Target : Target_sig.S) = struct
311353 let param_names = l @ [ f ] in
312354 let locals, body = function_body ~context ~param_names ~body in
313355 W. Function
314- { name; exported_name = None ; typ = func_type arity; param_names; locals; body }
356+ { name
357+ ; exported_name = None
358+ ; typ = None
359+ ; signature = func_type arity
360+ ; param_names
361+ ; locals
362+ ; body
363+ }
315364
316365 let f ~context =
317366 IntMap. iter
0 commit comments