Made the argument non optional
This commit is contained in:
parent
7ac567cc35
commit
7119ca1050
3 changed files with 5 additions and 4 deletions
|
@ -126,7 +126,7 @@ let types_of_param_list l = List.map (fun p -> p.p_type) l
|
|||
|
||||
let linearities_of_arg_list l = List.map (fun ad -> ad.a_linearity) l
|
||||
|
||||
let mk_arg ?(linearity = Ltop) name ty ck =
|
||||
let mk_arg name ty linearity ck =
|
||||
{ a_type = ty; a_linearity = linearity; a_name = name; a_clock = ck }
|
||||
|
||||
let mk_param name ty = { p_name = name; p_type = ty }
|
||||
|
|
|
@ -105,7 +105,7 @@ let rec vd_mem n = function
|
|||
let args_of_var_decs =
|
||||
(* before the clocking the clock is wrong in the signature *)
|
||||
List.map (fun vd -> Signature.mk_arg (Some (Idents.source_name vd.v_ident))
|
||||
vd.v_type Signature.Cbase)
|
||||
vd.v_type vd.v_linearity Signature.Cbase)
|
||||
|
||||
let signature_of_node n =
|
||||
{ node_inputs = args_of_var_decs n.n_input;
|
||||
|
|
|
@ -545,8 +545,9 @@ let translate_signature s =
|
|||
and translate_clock ck = match ck with
|
||||
| Cbase -> Signature.Cbase
|
||||
| Con(ck,c,x) -> Signature.Con(translate_clock ck, qualify_constrs c, x)
|
||||
and translate_arg a = Signature.mk_arg a.a_name (translate_type s.sig_loc a.a_type)
|
||||
(translate_some_clock a.a_clock)
|
||||
and translate_arg a =
|
||||
Signature.mk_arg a.a_name (translate_type s.sig_loc a.a_type)
|
||||
a.a_linearity (translate_some_clock a.a_clock)
|
||||
in
|
||||
let n = current_qual s.sig_name in
|
||||
let i = List.map translate_arg s.sig_inputs in
|
||||
|
|
Loading…
Reference in a new issue